home *** CD-ROM | disk | FTP | other *** search
/ The PC-SIG Library 10 / The PC-Sig Library - Shareware for the IBM PC and Compatibles (PC-SIG)(Tenth Edition Disks 1-2804)(1991).iso / PC_SIGCD / 04 / 3 / DISK0431.ZIP / ANALY.MQN / ANALY.MAN
Text File  |  1986-03-25  |  268KB  |  5,551 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.  
  10.  
  11.  
  12.  
  13.  
  14.  
  15.                          A N A L Y T I C A L C
  16.  
  17.  
  18.  
  19.                           The Analyst's Tool
  20.  
  21.  
  22.  
  23.                        User Manual and Reference
  24.  
  25.  
  26.  
  27.                        Copyright (C) 1985, 1986
  28.                                 G.C.E.
  29.  
  30. AnalytiCalc Reference Manual                                    Page 2
  31.  
  32.  
  33.  
  34.                          AnalytiCalc Overview
  35.                               AnalytiCalc
  36.  
  37.       AnalytiCalc  is an electronic spreadsheet program and integrated
  38.  system which was written in  "portable"  Fortran  and  runs  on  your
  39.  PDP11,  VAX  or  MSDOS  systems.   It  has  a variety of commands and
  40.  operates on a "command verb" syntax.  That is, everything you tell it
  41.  is  a  command.   Some  commands  enter  numbers or formulae;  others
  42.  manipulate them or change the  display.   Online  help  is  available
  43.  (though limited) via the Help command (or the F1 key).  
  44.  
  45.       While   the   primary   functionality  provided  is  that  of  a
  46.  spreadsheet, AnalytiCalc contains means for integrating word process-
  47.  ing  documents, running other programs under its control, integrating
  48.  its graphics output, and  accessing  data  files  created  either  by
  49.  selective  writes  from its own screens or by other programs.  Unlike
  50.  single huge programs which attempt to provide every function known to
  51.  Man in one image, AnalytiCalc is a "second generation" integrated en-
  52.  vironment which provides the "glue" that allows you to use  the  best
  53.  other  specialized programs you can find in a smooth way.  It is also
  54.  constructed to work smoothly with other "glue" systems (e.g.  TopView
  55.  (tm  IBM))  so that you need not give up the communications programs,
  56.  editors, word processors, or database managers you already have.  
  57.  
  58.       AnalytiCalc  has 5 major ways of addressing cells, over 78 func-
  59.  tions (more depending on how you count them), over 70 commands  (with
  60.  more variations), unlimited windowing and programmability at the cell
  61.  and the sheet level, 16 digit precision, and a built in online calcu-
  62.  lator.   It  is  designed to handle traditional spreadsheet problems,
  63.  data access problems, equation solving, engineering applications, and
  64.  finance,  and  is designed to be easy to extend both by adding to the
  65.  program itself and by adding commands externally.  The entire program
  66.  can be driven from a command file, and individual cells can be driven
  67.  by one or more command files in addition to  formulas;   commands  in
  68.  these  command  files  allow  programmable control of operations with
  69.  very high flexibility.  
  70.  
  71.       Interfaces  exist  to  graphics  outputs, to word processing in-
  72.  tegration with the spreadsheet (or AnalytiCalc may be used as a  word
  73.  processing  integration tool as a kind of framework document integra-
  74.  tor), to data access from data files separate from the sheet, and  to
  75.  saved  sheets  permitting  access to systems of spreadsheets.  Simple
  76.  methods of moving to other system commands make this program a power-
  77.  ful command interface as well as a unique analytic tool.  
  78.  
  79.       AnalytiCalc is command driven, though a number of these commands
  80.  are automatically generated  by  function  keys.   Its  commands  are
  81.  mnemonic and intended to be extremely fast to use once learned.  
  82.  
  83.  
  84. AnalytiCalc Reference Manual                                    Page 3
  85.  
  86.  
  87.  
  88.       Unlike  nearly  all other spreadsheet type products, AnalytiCalc
  89.  delivers what it promises.  If a cell can be  addressed,  it  can  be
  90.  used,  subject  only to limitations on the amount of disk storage you
  91.  allocate for backing store.  You can use any "n" cells (where "n"  is
  92.  18000  on  the PC) fully with enough disk backup.  Contrast this with
  93.  memory only systems which may address  500,000  or  more  cells,  but
  94.  which  permit only a few percent of these to be filled before running
  95.  out of room, even on large machines.  (For example, the popular 1-2-3
  96.  spreadsheet on IBM PCs is reported to hold at most around 12,000 sim-
  97.  ple formulas on a 544K machine, or  around  39,000  9-digit  numbers.
  98.  (Our  tests  have  run  out of room at less than 7000 cells on a 512K
  99.  AT.) In contrast, AnalytiCalc can hold 32,000 17-digit numbers,  long
  100.  formulas,  or  text  strings in its cells, using disk store as backup
  101.  for memory.  The 8088 version currently will run  in  256K  bytes  of
  102.  memory  and  handle  up  to 18,000 cells with up to 109 characters of
  103.  formula in each.  Thus the 8088 version can manage something over 2.1
  104.  megabytes   of   information,  while  programs  like  1-2-3  V1A  are
  105.  restricted to 0.3 megabytes approximately on normal memory PCs.) 
  106.  
  107.       Since  the  format  of a spreadsheet sometimes needs to vary, no
  108.  simple  fixed  size  can  satisfy  every  need.   For  that   reason,
  109.  AnalytiCalc  allows  its  storage  to  be repartitioned so that up to
  110.  18,000 columns or 18,000 rows may be used.  This is done  under  user
  111.  control  (with  normally  suitable  defaults) and allows use of cells
  112.  anywhere in the 18,000 by 18,000 space.  You cannot  fill  more  than
  113.  18,000  cells (chosen anywhere in the region, since there is no space
  114.  penalty for not using the upper left corner), but you have an address
  115.  range  of 324 million cells.  Legal column names range from A to ZPH,
  116.  and legal row names range from 1 to 18,000, and your display can show
  117.  any  of  this range in as many parts as there are cells shown on your
  118.  screen.  (One application of this would be to use columns  JAN,  FEB,
  119.  MAR,  APR,  MAY,  ...  and TOT for month oriented applications, using
  120.  D## forms of cell addressing to do cross-column sums, if you want  to
  121.  avoid  a line of labels.  This is more of a feat of virtuosity than a
  122.  production technique, but it will work and can be used as you like.) 
  123.  
  124.       Because  windowing  systems  (e.g.   the Topview system, or DESQ
  125.  (both trademarks)) work best  with  programs  that  use  DOS  writes,
  126.  AnalytiCalc  can  use  DOS  exclusively to write the screen.  Because
  127.  however DOS is fairly slow, AnalytiCalc also goes to some lengths  to
  128.  write  only a minimum number of characters to the screen.  This gives
  129.  a screen update which is slower than the author  really  would  like,
  130.  but which is highly usable nevertheless.  A side benefit is that this
  131.  program will run on anything  that  supports  ANSI  cursor  controls,
  132.  which  includes  almost  every MSDOS V2 or V3 machine.  A direct-BIOS
  133.  write mode is available also, for use wherever it  is  desired.   132
  134.  column  screens are supported by this program wherever DOS can handle
  135.  them.  AnalytiCalc runs on IBM  PC,  XT,  and  AT,  TAVA  PC,  Seequa
  136.  Chameleon,  Compaq,  Leading  Edge,  Columbia, Sperry, and most other
  137.  compatibles.  Some MSDOS machines (e.g.  Tandy 2000, IBM PCjr, Sanyo)
  138.  
  139. AnalytiCalc Reference Manual                                    Page 4
  140.  
  141.  
  142.  
  143.  require more memory than 256K to run AnalytiCalc because of their use
  144.  of larger amounts of memory for MSDOS or other machine functions.  
  145.  
  146.                                  ASIDE
  147.  
  148.       If  you  don't  have editors, communications software, DBMS sys-
  149.  tems, or the like, we recommend you look into the  Kermit  communica-
  150.  tions  package,  PC-FILE  for  a DBMS, and SCREEN, DVED, PC-WRITE, or
  151.  WORDFLEX for editors or wordprocessors.  If you need  these  applica-
  152.  tions, all the above are either public domain or "freeware".  You may
  153.  contact the PC Software Interest Group (PC-SIG) at  1030  E.   Duane,
  154.  Suite  J,  Sunnyvale,  California  94086, telephone 408-730-9291, for
  155.  further information or disks and catalogs of their  offerings.   They
  156.  have  about 400 disks full of free software at $6.00 per disk copying
  157.  fee.  You will find a selection of handy utilities on this  distribu-
  158.  tion  including  an  editor,  a calendar, and a primitive but generic
  159.  version of kermit (which can help you download a more recent  version
  160.  if you can use one) among others.  They may fill your needs.  
  161.  
  162.                              INTRODUCTION
  163.  
  164.       AnalytiCalc's  command  structure  is somewhat unique but simple
  165.  and logical once mastered.  Commands you learned for the  spreadsheet
  166.  system  of  your  choice generally are NOT the same as here.  But you
  167.  CAN perform all the same functions.  
  168.  
  169.       Remember  two  things  first:   in the default mode, you need an
  170.  Enter command ("E ") to enter text or numbers  into  the  sheet,  and
  171.  floating point numbers (most are floating point rather than integers)
  172.  need a period (.) in them to get AnalytiCalc  to  recognize  them  as
  173.  numbers rather than text.  If you forget the period, the numbers will
  174.  be displayed, but only as labels, and the cell will  have  a  numeric
  175.  value of zero.  
  176.  
  177.       If  you  want  a  more "traditional" command interface (entering
  178.  just numbers or formulas or labels/text by default and  starting  all
  179.  commands  with a "/", use the command /;  to get into that mode.  The
  180.  prompt will change from > to :  then as a flag and all commands  will
  181.  need to be entered as /command where the command text is as described
  182.  herein.  The descriptions here apply exactly to the  "command-mostly"
  183.  mode, which is the initial default.  The /;  mode is sometimes called
  184.  the "enter-mostly" mode, as  it  is  convenient  for  entering  large
  185.  amounts  of  textual  or  numeric information.  The command "//" gets
  186.  back to "command-mostly" mode.  
  187.  
  188.       You  can  have  as  many windows onto the sheet on screen as you
  189.  care to define.  Default operation will allow screen redrawing as you
  190.  move  beyond  the edges of the display.  This is more or less a stan-
  191.  dard type scrolling  operation,  and  windows  are  preserved  during
  192.  scrolls,  but  all  move together.  Separate scrolling can be handled
  193.  
  194. AnalytiCalc Reference Manual                                    Page 5
  195.  
  196.  
  197.  
  198.  easily via function keys if desired however.  The NS (NoScroll)  com-
  199.  mand can disable scrolling if desired.  
  200.  
  201.       If  the program's display is not as expected, use a V command to
  202.  redraw the screen and/or a R command to recompute to ensure the  dis-
  203.  play  is  really  incorrect.  Automatic recomputation occurs normally
  204.  when data is entered, so  most  invalid  conditions  due  to  forward
  205.  references in equations or lack of an extra recalculation after copy-
  206.  ing is done are corrected in the normal course of  use.   Because  of
  207.  the slowness of the PCDOS/MSDOS cursor controls, AnalytiCalc attempts
  208.  to update only regions of the display requiring it.  It  does  so  by
  209.  redrawing only cells that change value.  Occasionally a cell which is
  210.  modified from a TEst command or another cell, or a textual  cell,  is
  211.  not updated.  A View command (V) and/or a RF (Recalculate with Force)
  212.  command generally clear up any glitches.  
  213.  
  214.  
  215.                    Getting Started with AnalytiCalc
  216.  
  217.       The AnalytiCalc spreadsheet asks some questions when you run it,
  218.  to set up its working storage.  
  219.  
  220.                       Initial Questions (Startup)
  221.  
  222.  
  223.       Before AnalytiCalc begins with its screen-oriented operation, it
  224.  looks for a file (in the current directory) called ACINIT.PRM.  If it
  225.  exists,  it is read for replies.  If not, AnalytiCalc asks a question
  226.  about which screen control method to use.  AnalytiCalc can use either
  227.  ANSI  escape  sequences  to  control  the  screen (using the ANSI.SYS
  228.  driver in PCDOS and most flavors of MSDOS), or it  can  use  the  IBM
  229.  BIOS calls (via interrupt entries so they work on compatible machines
  230.  also) to handle screen writing.  Speed differences are not great, but
  231.  if  you do not load ANSI.SYS (or BIGANSI.SYS) for some reason and you
  232.  want to run the program, you can use direct screen control to do  so.
  233.  The question is:  
  234.  
  235.  Use ANSI.SYS cursor controls or IBM BIOS [A/I]:  
  236.  
  237.  Reply  either  A or I.  The default is ANSI controls.  Note that this
  238.  choice can be altered later by  the  VB,  VC,  or  VI  commands  (see
  239.  below),  so  it  is not critical.  If ANSI controls are selected, the
  240.  "Black and White" ANSI modes are used initially.  ANSI  controls  en-
  241.  able  highlighting  of  negative  numbers in black and white, but the
  242.  direct BIOS calls do not.  In color, negative numbers  are  displayed
  243.  in red, positive ones in yellow.  
  244.  
  245. AnalytiCalc Reference Manual                                    Page 6
  246.  
  247.  
  248.  
  249.       If  you  wanted  a  pre-prepared  set of replies for these, just
  250.  create a file ACINIT.PRM.  (You need to reply to the first page worth
  251.  of  questions  in  an ACINIT.PRM file, so the following example shows
  252.  sample replies to the others needed.) A simple way to set up replies,
  253.  requesting IBM BIOS video controls would be to type as follows:  
  254.  
  255.  $COPY CON: ACINIT.PRM
  256.  I
  257.  N
  258.  Any title desired - use ZA command to reset this.
  259.  22
  260.  22
  261.  1
  262.  1
  263.  _^Z
  264.  $
  265.  1 files copied.
  266.  
  267.  
  268.  Note  the  "^Z" means control-Z here.  The file just contains the re-
  269.  plies as though they were entered on the screen.  If the file exists,
  270.  the screen prompts will not appear however.  
  271.  
  272.       After  these commands are put in, any other desired commands can
  273.  also be included to further set up operation.  If you prefer to  come
  274.  up in "enter-mostly" mode, for example, you could put in a command /;
  275.  in this file.  If you are not using  ANSI.SYS  cursor  controls,  you
  276.  might initialize some of the AB0 through AZ0 formulas for commands as
  277.  described near the end of this document.  Initializing  commands  for
  278.  these  are  included  in  the  ACINIT.PRM  example  supplied  in  the
  279.  AnalytiCalc kits.  
  280.  
  281.  
  282.                             Initial Screen
  283.  
  284.       When  you  run  AnalytiCalc, it first asks you whether to change
  285.  the default  floating  point  format.   Most  numbers  are  "floating
  286.  point", which means they can have fractional values.  You will seldom
  287.  need integer numbers (which can take on  only  values  -2,000,000,000
  288.  ...   -3,-2,-1,0,1,2,3,4,...   2,000,000,000),  but  will  use normal
  289.  "floating point" ones in which it is legal to have values like  1.35,
  290.  2.5,  and so on.  Just think of "floating point numbers" as a synonym
  291.  for "numbers".  The display format for floating point numbers is ini-
  292.  tially  set  to the Fortran format F9.2 (9 characters wide, 2 decimal
  293.  places), but if you reply Y, it lets you enter any format you like as
  294.  the  default format.  It will try to use it, so if you enter an ille-
  295.  gal format, AnalytiCalc will keep asking for a format until it  finds
  296.  one  that  can display pi (3.14159) correctly.  Note that the default
  297.  sets the format when you first put a value or formula into a cell  to
  298.  be  displayed  numerically.  Once you fill a cell, its display format
  299.  
  300. AnalytiCalc Reference Manual                                    Page 7
  301.  
  302.  
  303.  
  304.  stays until you alter it with the DF command.  Thus if you enter some
  305.  values,  then use the S command (Setup) to change the format default,
  306.  and enter some more cells, only the second group of  numbers/formulas
  307.  entered  will  have the changed display format;  the first group will
  308.  not be changed.  You can have up to 75 separate formats on  a  sheet,
  309.  chosen from among anything that Fortran can display.  (A minitutorial
  310.  appears later in this manual.) 
  311.  
  312.       AnalytiCalc  then  asks  you to enter up to 80 characters as the
  313.  Title of the spreadsheet.  This is displayed at the top of the screen
  314.  and is used as a label for the sheet when printed out.  (The space is
  315.  made available for this rather  than  being  wasted  on  a  copyright
  316.  statement on your screen.) 
  317.  
  318.       To  reply,  enter  any title you like, up to 80 characters long,
  319.  followed (as all AnalytiCalc commands) by a  carriage  return.   This
  320.  will appear across the top of the sheet on screen and in print images
  321.  of it.  You may include any desired leading spaces in the title.   It
  322.  will  be  printed  on screen printouts, so make it descriptive of the
  323.  sheet you'll be using.  (Note it can be excluded  from  printouts  if
  324.  desired  when  row  and column headers are being skipped.) This title
  325.  remains until an S command is given (at which time you can change the
  326.  work  file  also),  though reading in a saved sheet also reads in the
  327.  saved title.  
  328.  
  329.                       Discussion of Scratch Files
  330.  
  331.       The  PDP11  and  PC  versions  of  AnalytiCalc use memory arrays
  332.  backed by temporary disk files for values and  formulas.   These  ask
  333.  how many K (bytes) to reserve on disk for the value file and the for-
  334.  mula file.  Generally there should be  somewhat  more  formula  space
  335.  than  value  space  if  many  long formulae are used;  otherwise pick
  336.  roughly equal values.  These scratch files are deleted on  exit  from
  337.  AnalytiCalc-PC,  but the sheet will NOT run out of room provided suf-
  338.  ficient file space is allocated.  If it runs out due to lack of room,
  339.  a  message on screen will tell which file is out.  Save the sheet and
  340.  restart then with a bigger file.  The  files  are  allocated  on  the
  341.  default disk when you run AnalytiCalc.  
  342.  
  343.                                 Detail
  344.  
  345.       Four questions are asked.  First, AnalytiCalc asks how many rows
  346.  and columns you expect to use on the sheet.  Try to  be  accurate  in
  347.  the  replies you give, but great precision is not necessary.  It will
  348.  then compute the necessary sizes of disk files assuming all the  area
  349.  you  gave  will  be solidly filled in and display these sizes for ad-
  350.  vice.  Then, it asks how many K to  allocate  to  value  and  formula
  351.  backing storage.  Reply with what you want to use on disk;  the files
  352.  will be allocated on your default disk and erased on exit.  
  353.  
  354.  
  355. AnalytiCalc Reference Manual                                    Page 8
  356.  
  357.  
  358.  
  359.       For  a  discussion  of the issues of storage allocation, see the
  360.  Appendix on this at the end of this manual.  
  361.  
  362.       When  these questions are answered, AnalytiCalc will display its
  363.  Calculation Screen.  
  364.  
  365.                       Calculation Screen Display
  366.  
  367.  
  368.       The  sheet is displayed at the top part of the screen and a com-
  369.  mand cell in Row 23 is shown with the current position encoded.  This
  370.  starts off looking like 
  371.  
  372.      A  1>   (if in "Command-mostly" mode)
  373.       or
  374.      A  1:   (if in "Enter-mostly" mode)
  375.  
  376.  
  377.  and  then  AnalytiCalc  awaits  your commands.  Note that if the cell
  378.  pointed to by the command (which is always a Physical sheet  address)
  379.  is occupied (i.e., has ever had any numbers or text entered into it),
  380.  that cell is displayed in the display in reverse video when  you  are
  381.  positioned there.  If the cell is totally empty, it is not displayed,
  382.  however, in any reverse video.  A pattern  of  blanks  is  displayed,
  383.  wherever the cell is null.  This pattern is in reverse video.  If you
  384.  use the CTTY command to run your PC from a remote  console,  a  VT100
  385.  type terminal can be used with AnalytiCalc because of the way it han-
  386.  dles the screen.  (In fact, a VT100 will permit you to use  the  full
  387.  132 column display of the screen for numbers.) 
  388.                                 CONTROL
  389.  
  390.       In "Command-mostly" mode (the default), AnalytiCalc is a COMMAND
  391.  DRIVEN spreadsheet system.  This means that you control the sheet  by
  392.  entering  a  command  followed  by Return.  These commands are in the
  393.  first few  columns  of  the  command  line  and  are  the  first  few
  394.  characters  (often  the first 1 or 2) you type, and they are REQUIRED
  395.  for every command.  AnalytiCalc does NOT assume  any  command  names.
  396.  AnalytiCalc  will translate inputs to upper case unless a " character
  397.  exists in the input string.   Many  of  the  most-used  commands  are
  398.  however  implemented  as single stroke function keys;  the ALT-F1 key
  399.  displays a diagram of these.  The numeric keypad has been implemented
  400.  in as mnemonic a way as possible also, so that arrow keys, home, end,
  401.  page up and down, and control left and right arrows  all  have  their
  402.  expected  meanings.   (For example, End goes to the end of the active
  403.  region, and the INSert key gets into  "Enter  Mode"  (F9  exits  that
  404.  mode) to allow continuous entry of data.) 
  405.  
  406.  
  407.  
  408. AnalytiCalc Reference Manual                                    Page 9
  409.  
  410.  
  411.  
  412.                                  NOTE
  413.  
  414.       If  your  function  keys don't work correctly this way, you
  415.       need to type AUXKPD.TXT to initialize ANSI.SYS for input.  
  416.  
  417.  
  418.  
  419.       (In  "Enter-mostly"  mode,  AnalytiCalc  is much more similar to
  420.  "traditional" spreadsheets in appearance.  If a / is seen to start  a
  421.  command, a one line prompt will appear in line 25 giving some initial
  422.  character mnemonics for commands.  It is not meant to be  exhaustive,
  423.  but just a reminder.) 
  424.  
  425.                                COMMANDS
  426.  
  427.       The commands available in AnalytiCalc are each described separa-
  428.  tely.  The following is  a  brief  listing  alphabetically  of  their
  429.  names.  Some infrequently used commands are omitted.  
  430.  
  431.   +J filename                Start journaling to filename 
  432.   +N                         Close journal file 
  433.   <                          Rewind input file 
  434.   %prompt%cmd%key%           Issue prompt and do cmd depending on key 
  435.   $ or }                     Perform operating system command 
  436.   > or >>pattern             Search for formula containing or starting
  437.                               with pattern 
  438.   *                          Comment line 
  439.   -prompt                    Load arguments after prompt 
  440.   //                         Use "Command-Mostly" mode 
  441.   /;                         Use "Enter-Mostly" mode 
  442.   /#                         Swap   current   mode   with   save  mode
  443.                               (command-mostly or enter-mostly) 
  444.   1,2,3, or 4                Move cursor Up, Down, Left, or Right 
  445.   @file.typ                  Read file.typ as input instead of console 
  446.   AA nn {R/C}                Add absolute nn rows or columns 
  447.   AR nn {R/C}                Add relocating nn rows or columns (nn may
  448.                               be neg) 
  449.   CA in-range out-range      Copy All (Absolute) 
  450.   CV in-range out-range      Copy Value 
  451.   CF in-range out-range      Copy Formula (and Format) 
  452.   CR in-range out-range      Copy Relocating (all) 
  453.   DB ncol,nrow               Display Bounds (no.  cols,rows on screen) 
  454.   DF range [format]          Display Format of range to format 
  455.   DL range {R/C}n:m          Display  Locate  range as Row/Col to dis-
  456.                               play col:row n:m 
  457.   DS{R/C}{A/D} n             Display Sort row/col, Asc/Desc row/col n 
  458.   DT range {F/I}             Display Type range as Float or Integer 
  459.   DW ncol,wid                Display  Width  of  col  "ncol"  to "wid"
  460.                               chars 
  461.   E expression               Enter expression into cell 
  462.  
  463. AnalytiCalc Reference Manual                                   Page 10
  464.  
  465.  
  466.  
  467.   E" expression              Enter   expression   as   text,  no  case
  468.                               translation 
  469.   ED 'oldstring'newstring'   EDit cell 
  470.   ET expression              Enter expression as UPPER CASE text 
  471.   EV expression              Enter expression as computable formula 
  472.   F filename/nskip           File read from filename onto display 
  473.   G                          Get saved sheet.  Many variants.  
  474.   Hn                         HELP and show page n 
  475.   IR inrange outrange        In  Place Relocate inrange as if moved to
  476.                               outrange 
  477.   K                          Go   into  interactive  calculator  (need
  478.                               *V 3).  *E goes back.  
  479.   L cell                     Go to cell 
  480.   M{0/1/2/3/4/5}             Move - set move direction after enter 
  481.   MS or MH                   Macrocell Show or Hide - show or hide in-
  482.                               cluded files.  
  483.   OA cell                    Origin  Absolute  cell  - Map Screen with
  484.                               cell in upper left 
  485.   OAD cell                   Origin   Absolute  Displace  cell  -  Map
  486.                               Screen with cell in upper  left  leaving
  487.                               old windowing alone 
  488.   OR cell                    Origin   Relative   cell   -  map  screen
  489.                               down/right of cursor with cursor=cell 
  490.   ORD cell                   Origin   Relative  Displace  cell  -  map
  491.                               screen   down/right   of   cursor   with
  492.                               cursor=cell leaving old windows 
  493.   OV +                       OVerride absolute refs, make relative 
  494.   OV -                       OVerride off - let abs refs be absolute 
  495.   P                          Put (save) spreadsheet.  Many variations. 
  496.   R                          Recalculate sheet 
  497.   RB cell                    Set Relocate Boundary at cell 
  498.   RF                         Recalculate, Force recalc of constants 
  499.   RM                         Recalculate  Manual  -  no recalc until R
  500.                               cmd 
  501.   S                          Setup - Global mapping/width/title setups 
  502.   TE expression              TEst  -  Evaluate  math expression in cmd
  503.                               mode - many special variants.  
  504.   V                          View - Redraw screen 
  505.   VF                         View  Formulas  -  Draw with Formulas in-
  506.                               stead of numbers 
  507.   VM                         View Manual - no screen repaint until a V
  508.                               cmd 
  509.   W                          Write display to file or printer.  
  510.   X                          eXit  from AnalytiCalc.  Asks for confir-
  511.                               mation.  
  512.   ZE range               ZEro range of cells 
  513.   ZA                         Zero  All  of  sheet.  Asks for confirma-
  514.                               tion.  Also used for reinitializing.  
  515.  
  516.  
  517. AnalytiCalc Reference Manual                                   Page 11
  518.  
  519.  
  520.  
  521.                           INDIVIDUAL COMMANDS
  522.  
  523.  
  524.                            Moving the Cursor
  525.  
  526.          CURSOR MOTION (Commands to move around
  527.                         the sheet one cell at a time)
  528.  
  529.          1               (Move up)     (or uparrow)
  530.          2               (Move down)   (or down arrow)
  531.          3               (Move left)   (or left arrow)
  532.          4               (Move right)  (or right arrow)
  533.  
  534.  
  535.       The  cursor  motion  keys  move the cursor on the display in the
  536.  direction indicated.  Note these keys are in the same  order  on  the
  537.  keyboard as the arrow keys of the VT100.  
  538.  
  539.       NOTE THAT THE KEYS 1 TO 4 ARE INTERPRETED IN THE SAME WAY AS THE
  540.  UP, DOWN, LEFT, AND RIGHT ARROW KEYS ON THE VT100.   THEY  APPEAR  IN
  541.  THE SAME ORDER AS THE ARROW KEYS ON THE VT100 ON THE KEYBOARD.  
  542.  
  543.       The  X  and  Y accumulators are set to the column number and the
  544.  (row number + 1) respectively  during  commands.   This  allows  pro-
  545.  cedures  to detect cursor position or motion where useful.  These ac-
  546.  cumulators may be used within cells  for  anything;   resetting  them
  547.  does not move the cursor.  
  548.  
  549.       If the arrow keys move to the edge of the screen (or if auto mo-
  550.  tion does this), an automatic  OA  command  is  done  to  effectively
  551.  scroll  the  entire  viewing  screen by the number of rows or columns
  552.  minus 2.  The command  NS  (meaning  No  Scroll)  will  inhibit  this
  553.  redrawing.   The scrolling can be re-enabled by giving the command SC
  554.  (SCroll).  These commands do not redraw anything nor  do  they  cause
  555.  recalculation;   they merely toggle an internal control.  The initial
  556.  state is SCroll mode.  
  557.  
  558.  
  559.  
  560. AnalytiCalc Reference Manual                                   Page 12
  561.  
  562.  
  563.  
  564.                    Insert or Delete Rows or Columns
  565.  
  566.        ADJUSTING PHYSICAL LOCATIONS
  567.        (Adding or Removing Rows or Columns)
  568.      AA  number  R     Add "number" rows ahead of the current physical
  569.             position, moving all cells below the current cell down  by
  570.             "number"  rows  and  losing  the  physical  sheet's bottom
  571.             "number" rows' contents, NOT adjusting variable references
  572.             where the variables are in the moved range and are not the
  573.             position independent (P## or D## forms) type.  
  574.      AA  number C     Add "number" columns ahead of the current physi-
  575.             cal position, moving all cells right of the  current  cell
  576.             right  by "number" columns and losing the physical sheet's
  577.             bottom "number" columns' contents, NOT adjusting  variable
  578.             references  where the variables are in the moved range and
  579.             are not the position independent (P## or D## forms) type. 
  580.      AR  number  R     Add "number" rows ahead of the current physical
  581.             position, moving all cells below the current cell down  by
  582.             "number"  rows  and  losing  the  physical  sheet's bottom
  583.             "number" rows'  contents,  adjusting  variable  references
  584.             where the variables are in the moved range and are not the
  585.             position independent (P## or D## forms) type.  
  586.      AR  number C     Add "number" columns ahead of the current physi-
  587.             cal position, moving all cells right of the  current  cell
  588.             right  by "number" columns and losing the physical sheet's
  589.             bottom  "number"  columns'  contents,  adjusting  variable
  590.             references  where the variables are in the moved range and
  591.             are not the position independent (P## or D## forms) type. 
  592.  
  593.       These  commands  permit  the  operations  known  on other spread
  594.  sheets as "insertion" or  "deletion".   Deletion  takes  place  where
  595.  "number"  is negative and the sense of the motion is reversed.  These
  596.  commands change the physical sheet's contents  and  permit  wholesale
  597.  modifications  to  variable  names (other than P## or D## forms which
  598.  are position independent already and are left  alone  for  simplicity
  599.  and to preserve some of the flexibility of the D## forms which can be
  600.  used for projections of 3D sheets onto  the  display  and  math  with
  601.  ranges  of these).  To save a sheet for merging such selected values,
  602.  both forms, or at least the numeric form, of the Put commands  should
  603.  be used.  
  604.  
  605.       Note  that the previous contents of the rows or columns inserted
  606.  is RETAINED, though it can be zeroed by the ZE  command  if  desired.
  607.  It  will  have  been  copied  also  to  the  lower  or  further-right
  608.  row/column also, but do not be alarmed;  the space is free to re-use.
  609.  You may however elect to use this feature as a shorthand for copy.  
  610.  
  611.       The AR/AA operations take place on the physical sheet and do not
  612.  affect the display sheet mapping to the physical sheet.  
  613.  
  614. AnalytiCalc Reference Manual                                   Page 13
  615.  
  616.  
  617.  
  618.  
  619.  
  620.                      Copying and Replicating Cells
  621.  
  622.       COPYING CELLS
  623.  
  624.     CA V1:V2 V3:V4    Copy all cell attributes from V1:V2
  625.                        to V3:V4.
  626.     CV V1:V2 V3:V4    Copy numeric values only
  627.     CD V1:V2 V3:V4    Copy Display Formats only
  628.     CF V1:V2 V3:V4    Copy Formulas only (no relocation)
  629.     CR V1:V2 V3:V4    Copy all cell attributes as in CA
  630.                 but relocate cell names to new location
  631.                 from old one. Only relocate names right
  632.                 of or below the cursor or on same row/col
  633.                 with cursor (cells above or left of cursor
  634.                 are NOT relocated).
  635.     IR V1:V2 V3:V4    Relocate formulas inplace, computing
  636.                 displacements using distance "moved".
  637.  
  638.  
  639.       The Copy commands let you reproduce cells' contents in other lo-
  640.  cations on your sheet without re-entering them.  The CA form is  most
  641.  useful,  though the CD part can be used to change default formats and
  642.  the others may be handy.  Note that formulas are NOT changed  by  the
  643.  copy operation.  If they should function correctly in their new loca-
  644.  tion relative to different cells, the cell identifications should  be
  645.  position  independent  forms  (P#n#m  for  forms relative to physical
  646.  sheet, D#n#m for forms relative to display sheet) so no  modification
  647.  is  necessary.  CA will normally save all information about a cell in
  648.  the new cell.  
  649.  
  650.       Unlike  the other C class commands, the CR command WILL relocate
  651.  any variable names that are below or to the right of  the  cursor  at
  652.  the time the command is given.  Names above or left of the cursor are
  653.  not changed.  The row and column the cursor is in is included in  the
  654.  relocation  region.  Thus, to be sure names are relocated, use a com-
  655.  mand like L A1 first to position yourself at the top left part of the
  656.  physical  sheet.   BE  SURE  YOU  DO THE REPOSITION IF YOU USE THE CR
  657.  COMMAND!!!!!!!  Note however that if you need certain cells NOT to be
  658.  relocated, the ability to place them above or left of the cursor when
  659.  copying or replicating cells around and having them left alone can be
  660.  useful.   Normalization  factors,  for  instance,  can  be left alone
  661.  (e.g., at the top of a column) and cells referring to them be  copied
  662.  without having them point to the "wrong" normalization cell.  
  663.  
  664.       When  you  specify  one  variable to the C class commands in the
  665.  V1:V2 range location and give a range V3:V4, the  command  will  copy
  666.  the named V1 into all cells in the V3:V4 range.  
  667.  
  668.  
  669. AnalytiCalc Reference Manual                                   Page 14
  670.  
  671.  
  672.  
  673.       The  IR  command  allows  inplace  relocation of formulas.  This
  674.  operates from the cursor to the Relocate Boundary (see  below).   The
  675.  *U HERE function returns the current maximum column used in the W ac-
  676.  cumulator and the current maximum row used in the  Y  accumulator  to
  677.  permit  the repeated use of IR from a command file to simplify moving
  678.  sections of the sheet.  
  679.  
  680.  
  681.                    Setting Size of Display on Screen
  682.  
  683.        DISPLAY BOUNDARIES SETTING (Number rows/cols)
  684.  
  685.      DB n,m    Set number of columns displayed on screen
  686.                  to n, number of rows displayed to m.
  687.  
  688.       The DB command sets display size.  It also effects the number of
  689.  cells modified by the OA and OR  commands,  so  setting  the  display
  690.  small,  doing an OA or OR, then setting it large, leaves the part om-
  691.  itted as it was before the OA or OR.  The displayed window also  con-
  692.  trols  what  is  read in with the F command.  Note that for automated
  693.  text retrieval, the VM command (to turn  off  redisplay  during  com-
  694.  mands)  may  be  useful  in connection with using DB commands, F com-
  695.  mands, and then V commands to turn the display updating back on  from
  696.  command  files  invoked either by auxiliary keypad keys or from @file
  697.  commands.  
  698.  
  699.  For an example of DB, if you want a display of 14 columns by 20 rows,
  700.  the command 
  701.        DB 14,20 
  702.  would be the way to achieve it.  
  703.  
  704.       When  a narrow screen (e.g.  a 40 column screen) is used, the DB
  705.  command may be used to reduce the number of columns  shown  to  allow
  706.  AnalytiCalc  to  operate.   If  your  screen  supports  more  than 80
  707.  columns, AnalytiCalc will allow their use by increasing the number of
  708.  columns seen.  
  709.  
  710.       The  maximum bounds for DB are usually larger than a real screen
  711.  will hold, but the W command will write out up to these larger bounds
  712.  to  allow  long sheet printouts.  On the 8088 version, up to 75 lines
  713.  length are permitted per page.  
  714.  
  715.  
  716.  
  717. AnalytiCalc Reference Manual                                   Page 15
  718.  
  719.  
  720.  
  721.                         Setting Display Format
  722.                                   and
  723.               Changing between Formula and Number Display
  724.  
  725.        DISPLAY FORMAT SETTING
  726.  
  727.        DF V1:V2 [format]   Set Display Format AND
  728.                              set up whether to
  729.                              display formula or number
  730.  
  731.  
  732.       The DF command sets the display format for the variable range V1
  733.  to V2 inclusive to be whatever is in the square  brackets.   This  is
  734.  expected  to  be  a valid FORTRAN FORMAT specifier for display of the
  735.  number and may be up to 9 characters long.  If the  format  specifier
  736.  entered  is  however  just A or L in the first character, the program
  737.  will indicate the text is to be displayed literally, not as a number,
  738.  so  titles and such can be shown.  To display numbers in Fortran A or
  739.  L forms, just use formats like 4A1 or similar;  as long as  there  is
  740.  something  ahead  of the A or L it goes to Fortran.  The program will
  741.  try your format once before writing to disk  to  ensure  against  any
  742.  crashes  that  will damage your file.  Otherwise, the format is up to
  743.  you.  You can even display in octal or hex if you wish!  
  744.  
  745.       The  DF command is used to switch a cell from display of numeric
  746.  information to formula/text display or back on a cell by  cell  basis
  747.  (the  VF  command globally switches cells from numeric to formula and
  748.  back, though a cell set to  display  text  with  DF  always  displays
  749.  text).   To  change  a  cell to numeric, merely use the DF command to
  750.  give it a numeric format (the default is normally F9.2 so the command
  751.  to set, say, cell G3 to be numeric (possibly after entering a formula
  752.  not containing +, -, ., (, or [ characters) would be:  
  753.  
  754.      DF G3 [F9.2] 
  755.  
  756.  for the standard Fortran F9.2 format (2 decimal places, 9 digits wide
  757.  display).  In AnalytiCalc-VM, every cell may have an entirely  unique
  758.  format.   In  AnalytiCalc-PC, however, only a finite number of unique
  759.  formats is possible (usually about 45) since storage  is  in  memory.
  760.  The  design  limit  is  255 unique formats, but very few spreadsheets
  761.  will need more than the 45 normally provided.  Typical ones only have
  762.  2  or  3  unique  formats.   The  formats  may be ANY Fortran formats
  763.  desired.  
  764.  
  765.       The  DF command will also set the type to Floating if the format
  766.  begins with F or E, and will set the type to Integer  if  the  format
  767.  begins with I.  Beyond this (e.g., for octal or hex) you must use the
  768.  DT command (below) to set the storage to floating (8  bytes)  or  in-
  769.  teger (4 bytes).  
  770.  
  771.  
  772. AnalytiCalc Reference Manual                                   Page 16
  773.  
  774.  
  775.  
  776.       The  DF command will attempt to avoid erroneous format inputs by
  777.  trying the format out on your current location.  If errors occur, the
  778.  DF  command  will be quietly ignored, and the program will not crash.
  779.  This makes it difficult to switch to integer displays.  To  switch  a
  780.  cell  or  range  to  integer, you must use the L command to move to a
  781.  cell not shown on the screen, then use the DT command to  change  the
  782.  desired  cells to integer type, then use the DF command to change the
  783.  display format to an integer display format.   The  cells  will  then
  784.  work  correctly  as  integer  cells.   Note  this checking is done by
  785.  AnalytiCalc-Vm and AnalytiCalc-PC only.  
  786.  
  787.       A  cell  may be switched back to* its previous numeric format by
  788.  using the command DF v1 [*] where v1 may be a cell  or  range.   This
  789.  allows  temporary  examination  of  formulas and resetting to numeric
  790.  without losing the format.  
  791.  
  792.                            What Is Displayed
  793.  
  794.           NOTE:  
  795.           There are 2 items in any cell which may be  displayed.   One
  796.           of  these  is the number in the cell, which takes 4 bytes if
  797.           an integer, 8 if floating point, and which is displayed nor-
  798.           mally  using  a  Fortran  FORMAT statement type declaration.
  799.           The other is the FORMULA associated with the cell, which may
  800.           contain just text or labels.  This is selected by the A or L
  801.           formats.  
  802.  
  803.                Thus, the declaration 
  804.           DF A1:A64 [8A1] 
  805.           would  display  the NUMBERs in column A as 8 characters (as-
  806.           suming this makes sense), and would cause strange errors  if
  807.           the number did not make sense as characters.  
  808.           The declaration 
  809.           DF A1:A64 [A] 
  810.           would  display  the  FORMULA TEXT in column A on the screen.
  811.           This normally will always make sense, and is the normal  way
  812.           to display labels.  
  813.  
  814.                          FORMAT microtutorial
  815.  
  816.       To  reset  FORTRAN  Formats, the Fw.d format is useful.  In that
  817.  format, w means an integer giving the width in characters of the out-
  818.  put  number,  and d is the number of decimal places to be shown.  For
  819.  example F9.2 has 9 places total, 2 to the right of a  decimal  point.
  820.  A valid number in this format might be (supposing its' exact value is
  821.  123456.782) 
  822.       123456.78 
  823.       The format F9.1 would give 
  824.       123456.8 (note rounding) 
  825.       The format F10.3 would give 
  826.  
  827. AnalytiCalc Reference Manual                                   Page 17
  828.  
  829.  
  830.  
  831.       123456.782 
  832.  
  833.       You   may   devise   whatever  formats  desired.   In  addition,
  834.  AnalytiCalc will only display the number of characters  that  fit  in
  835.  the column on screen, so display width can be set to remove undesired
  836.  decimals.  
  837.  
  838.                           Other FORMAT types
  839.  
  840.       The  default F9.2 format occupies 9 of the default 10 characters
  841.  of column width.  Where additional labels are needed, the 1Hc or 2Hcc
  842.  formats may be used.  For example, to show dollars, one might write a
  843.  format as [1H$,F9.2] in the DF command.  If  as  an  alternative  one
  844.  wanted  to show thousands of dollars with one decimal place, a format
  845.  like [2H$K,F9.1] would place "$K" ahead  of  each  number.   Thus,  a
  846.  value of 345.67 in the first format would look like 
  847.  $ 345.67 
  848.  and in the second format it would look like 
  849.  $K 345.7 
  850.  (since the spreadsheet only knows numbers, not their dimensions).  
  851.  
  852.       Where it is desired to display large numbers, FORTRAN offers the
  853.  E and G formats (the form of such a format is Ew.d or Gw.d where w is
  854.  the  width  of  the  number as printed and d is the number of decimal
  855.  points).  The E format displays the number as a fraction followed  be
  856.  E  followed  by a power of 10.  The G format chooses a floating point
  857.  display or an E format depending on the number's size.  Note that  in
  858.  E  and G formats, there need to be 4 spaces in the decimal field just
  859.  for the exponent.  
  860.  
  861.       The  format  you  display  in may be wider than the column;  the
  862.  first "n" characters of the number are shown, where "n" is the  width
  863.  of  the column.  Thus, if you use a format like F10.0 (which displays
  864.  10 digits followed by a period), the period  will  not  show  in  the
  865.  default 10 character column width.  
  866.  
  867.       Available  format  designators  for  floating  numbers (the ones
  868.  you'll use almost always) are:  
  869.      Fw.d  - Simple display with w characters of display (counting the
  870.  decimal point) and d decimal places after the decimal;  
  871.      Ew.d  - Display as a fraction followed by Enn where nn is the ex-
  872.  ponent of 10 to multiply the fraction by.  The format kPEw.d causes k
  873.  digits  to  be  displayed to the left of the decimal place, so that a
  874.  format of E10.5 might display the number 73.453 as ".73453E+02" and a
  875.  format of 1PE10.4 would display it as "7.3453E+01".  The w is the to-
  876.  tal number of characters in the display, and  the  d  the  number  of
  877.  decimals shown.  Note that the w must have 4 extra characters to han-
  878.  dle the "E+nn" part of the number.  Very large or small  numbers  can
  879.  be handled by this format where they would be too wide in F format.  
  880.      Gw.d - This format works like the Fw.d format provided the number
  881.  
  882. AnalytiCalc Reference Manual                                   Page 18
  883.  
  884.  
  885.  
  886.  is small enough to fit in the widths  provided,  and  like  the  Ew.d
  887.  format otherwise.  The display will include only d digits (or k+d di-
  888.  gits if using kPGw.d), so for cases where it works, the  Fw.d  format
  889.  is more space efficient.  
  890.      Several "modifier" formats are available.  nHxx allows characters
  891.  xx in the output.  nX includes n spaces.  TRc causes the next  output
  892.  to  appear  c spaces right of the current one, and 'xx' acts like the
  893.  nHxx in outputting characters xx.  The 'xx' or nHxx designators  must
  894.  be  separated  by comma from following format designators.  Also Dw.d
  895.  is equivalent to Ew.d.  The optional forms Ew.dEe and Gw.dEe act like
  896.  Ew.d and Gw.d except that only e digits of exponent are displayed.  
  897.  
  898.  
  899.                 Fine Control Remapping Displayed Cells
  900.  
  901.       DISPLAY LOCATE (Map physical sheet variables
  902.                       onto Display Sheet)
  903.    DL  V1:V2 Rn:m    point at display coordinates (n,m) (col,row) and,
  904.           going left to right  along  a  Row,  copy  in  variables  V1
  905.           through  V2  (actually,  point  those display sheet cells at
  906.           variables V1 thru V2).  
  907.    DL  V1:V2 Cn:m    point at display coordinates (n,m) (col,row) and,
  908.           going top to bottom along a Column,  copy  in  variables  V1
  909.           through  V2  (actually,  point  those display sheet cells at
  910.           variables V1 thru V2).  
  911.  
  912.       The  DL command lets you associate any variables in the physical
  913.  sheet with any location on the display sheet (the display sheet coor-
  914.  dinates  always  count  from 1 as the topmost row or leftmost column,
  915.  through the maximum number there).  This flexible  association  means
  916.  that  in  principle every cell on the display sheet can be a "window"
  917.  in the sense of other sheets, though that would be quite hard to fol-
  918.  low.   If  the  :V2 part of the command is left off, only one display
  919.  cell is changed.  This command is present to give "fine grained" dis-
  920.  play  control.   Most of the time the OA and OR commands will be used
  921.  instead, but this command allows you to tailor a display  as  needed.
  922.  It  is recommended that the journalling be turned on before you issue
  923.  many DL commands to capture them into a file that can be played  back
  924.  (via @file) to recreate the display mapping.  The +J file and +N com-
  925.  mands turn journalling on and off.  
  926.  
  927.  
  928.  
  929. AnalytiCalc Reference Manual                                   Page 19
  930.  
  931.  
  932.  
  933.                     SORTING DISPLAY ROWS or COLUMNS
  934.          SORTING DISPLAYS
  935.  
  936.     DSRA#nn   Sort display on row/col nn (display coord)
  937.  
  938.  
  939.       The  DS  command  sorts  "normally"  ordered display sheets.  It
  940.  operates something like a sorted OA command, the sort key  being  the
  941.  number in a column or row.  The command looks like this:  
  942.  DS Command specifier 
  943.  R  or  C  - Row or Column specifier (i.e.  whether to sort a row or a
  944.  col.) 
  945.  A or D - Ascending or Descending order sort 
  946.  nn - row or column number to sort on.  
  947.  
  948.       The command letters must all appear together.  Thus a command to
  949.  sort Column 4 on the display in Descending order would be:  
  950.  DSCD 4 
  951.  and a command to sort Row 3 in Ascending order is:  
  952.  DSRA 3 
  953.  
  954.  The  sheet  should be in "normal" order (as from an OA command) prior
  955.  to the sort for use.  The area sorted is the part of the  sheet  dis-
  956.  played  (set  by the DB command, so it may actually exceed what shows
  957.  on the screen.  The 8088 version  of  AnalytiCalc  normally  supports
  958.  very  large display sheets to permit printout of large displays which
  959.  are not all visible on the screen;  the screen display  discards  all
  960.  the  un-displayable  points, but the print routine, and the sorts, do
  961.  not.) That is, the display sheet size may be  given  as  larger  than
  962.  your  screen  will  display, and the sort will cover that area.  Note
  963.  that ONLY display sheet locations are sorted.  A sort on the PHYSICAL
  964.  sheet  may  be  done  via a cell or sheet program, but this primitive
  965.  does not.  
  966.  
  967.  
  968.  
  969. AnalytiCalc Reference Manual                                   Page 20
  970.  
  971.  
  972.  
  973.                            DATA TYPE control
  974.  
  975.        DATA TYPE SETTING
  976.  
  977.      DT V1:V2 F    Set V1 thru V2 to Floating data type
  978.      DT V1:V2 I    Set V1 thru V2 to Integer data type
  979.  
  980.  
  981.       The  DT command sets Float/Integer attributes on physical cells.
  982.  Initial default is F (8 bytes) but this can set it to I (4  byte  in-
  983.  teger).   Computation  is  done  in floating point always, but I type
  984.  variables will be converted to integer when stored and  may  be  dis-
  985.  played in valid Fortran formats.  This information is stored/restored
  986.  by the P/G class commands.  The type flag may also be set with  a  DF
  987.  command,  which  recognizes I formats as implying that data is of in-
  988.  teger type (if the first character of the format is an I)  and  treat
  989.  other  formats  as  floating point (real) data.  The integer data can
  990.  hold up to + or - about 2 billion.  The floating point representation
  991.  permits  nearly  unlimited size numbers but only has 16 (roughly) di-
  992.  gits precision.  Integer  arithmetic  is,  within  its  valid  range,
  993.  exact.   When  integer data is retrieved, it is converted to floating
  994.  point for calculations and converted back upon storage;  this  avoids
  995.  many potential internal problems of function validity.  
  996.  
  997.  
  998.                          Setting Column Width
  999.  
  1000.          DISPLAY WIDTH SETTING
  1001.  
  1002.      DW N,M     Set column N on display to be M
  1003.                    characters wide
  1004.  
  1005.  
  1006.       DW  lets you set any column width.  They are independent of each
  1007.  other, and may be set in any order.  Maximum width supported  is  132
  1008.  columns.  Note that when many widths are to be varied, the VM mode is
  1009.  useful to prevent redrawing the screen between settings;  the V  mode
  1010.  can  then  be  reset  once the widths are as desired.  Setting column
  1011.  widths is expected to be frequently done via a command file (see  the
  1012.  @ command below).  The column number is normally displayed across the
  1013.  top of the screen along with the physical  cell  the  display  column
  1014.  currently  is  pointing  to  on the top row.  This is shown in a form
  1015.  like "AF = 4" in reverse video (or different colors).  You use the  4
  1016.  in  this command.  Because some commands (notably this one and the DL
  1017.  command above) use DISPLAY coordinates, the columns are  labelled  in
  1018.  this  way  to make it easy.  Rows are not labelled because the labels
  1019.  take too much space on screen.  
  1020.  
  1021.  
  1022.  
  1023. AnalytiCalc Reference Manual                                   Page 21
  1024.  
  1025.  
  1026.  
  1027.                              EDIT command
  1028.  
  1029.          EDIT FORMULAS
  1030.  
  1031.   ED 'string1'string2'  Replace string1 with string2
  1032.                         in current cell formula. Either
  1033.                         string may be null if desired.
  1034.  
  1035.  
  1036.       The  ED command allows editing of formulas with some extra bells
  1037.  and whistles.  Basically, the new string replaces the old one, EXCEPT
  1038.  that it is possible to do some limited argument replacement.  
  1039.  
  1040.       The  constructs  &1  through  &4 will be replaced by arguments 1
  1041.  through 4 as last entered by the "-" command (see below).  These  may
  1042.  be  from  0 to 51 characters long each, and multiple & constructs may
  1043.  appear in a substitution.  No & constructs may recurse,  however.   A
  1044.  second  ED command can have the effect of the recursion in some cases
  1045.  however.  
  1046.  
  1047.       The  construct &5 will evaluate accumulator Z and, if it is in a
  1048.  range where it may be so represented, take its integer part and  con-
  1049.  vert it to a numeric string (up to 10 characters) in the place of the
  1050.  &5.  
  1051.  
  1052.       The  construct &6 will replace the cell with the contents of the
  1053.  integer part of accumulator Z provided that that number is between  1
  1054.  and  256.   Thus, any single non-null ASCII code can be entered.  Ac-
  1055.  cumulator Z is used to avoid conflicts with %, which is used too fre-
  1056.  quently  to reserve for this purpose.  To set up Z interactively to a
  1057.  constant, the command "TE Z=nn." will set Z to the value nn.  
  1058.  
  1059.       The EDited formula is re-entered into the cell after the edit.  
  1060.  
  1061.       If  the  initial  string  is  null, the EDit command appends the
  1062.  replacement string onto the contents of the cell.  If the replacement
  1063.  string  is null, the corresponding contents of the cell's formula are
  1064.  deleted.  Note that ALL matching strings in the formula are replaced,
  1065.  not  just the first.  If automatic motion has been specified after an
  1066.  Enter, it also occurs after an EDit.   This  allows  a  "dummy"  EDit
  1067.  (e.g.   ED  / / /)  to  simply  move in the default direction without
  1068.  changing any formulas.  
  1069.  
  1070.  
  1071.  
  1072.  
  1073. AnalytiCalc Reference Manual                                   Page 22
  1074.  
  1075.  
  1076.  
  1077.                                  ENTER
  1078.  
  1079.                 (Entering Data and Expression Formats)
  1080.  
  1081.          E expression       Enter expression and set as formula
  1082.                                or text based on contents
  1083.          ET expression      Enter expression and set as text
  1084.          E" expression      Enter expression and set as text.
  1085.                                Note this form does NOT
  1086.                                translate to upper case.
  1087.          EV expression      Enter expression and treat as
  1088.                                computable.
  1089.  
  1090.  
  1091.       This  command enters the given expression at your current cursor
  1092.  position, and may optionally move in some direction that has been set
  1093.  up by the M command (Move) after the entry is made.  
  1094.  
  1095.       The Expression may be text or one or more numbers, functions, or
  1096.  equations (separated by the \ (backslash) character if more than  one
  1097.  per cell) in fully parenthesized infix notation.  The expressions en-
  1098.  tered resemble normal algebraic expressions, with the usual  operator
  1099.  precedence.  There are 26 global accumulators named A through Z (plus
  1100.  a special one named %) available;  the result  of  a  calculation  is
  1101.  always  left  in  the  %  accumulator as well as the cell.  Operators
  1102.  available include addition (+), subtraction (-), multiplication  (*),
  1103.  division  (/),  and exponentiation (** or !), with normal precedence.
  1104.  Many functions are also available, described below, for other  opera-
  1105.  tions.   The  operator evaluation order is functions, exponentiation,
  1106.  multiplication and division, addition and  subtraction,  just  as  in
  1107.  Fortran  and  most  programming  languages (and on most calculators).
  1108.  Parentheses may be used  to  group  calculations  to  override  these
  1109.  defaults.  
  1110.  
  1111.       Simple examples of Enter are:  
  1112.  
  1113.  E 523.458         Enter the number 523.458 into
  1114.                     the current cell
  1115.  E SUM[A3:A15]     Enter the formula to compute the
  1116.                     sum of cells A3 through A15 and
  1117.                     produce the result in the current
  1118.                     cell
  1119.  E MONTHLY REVENUES 
  1120.                    Enter the label "MONTHLY REVENUES"
  1121.                     into the current cell. Notice that
  1122.                     the string does NOT have any of the
  1123.                     characters .[(+_ in it, so it is
  1124.                     treated by default as a label.
  1125.  E (A2+A4+A6+A8+A9*A10+A11*A12)/(SUM[A2,A4,A6,A8]-A13)
  1126.                    Places the above formula into the cell
  1127.  
  1128. AnalytiCalc Reference Manual                                   Page 23
  1129.  
  1130.  
  1131.  
  1132.                     so that it will be evaluated. The
  1133.                     multiplications and divisions are done
  1134.                     before additions and subtractions, as
  1135.                     is the normal mathematical standard.
  1136.                     The formulas may of course contain
  1137.                     references anywhere on the sheet; they
  1138.                     do NOT have to all refer to the same
  1139.                     row or column.
  1140.  
  1141.       The  text  entered  becomes  the  Formula  for  that  cell,  and
  1142.  AnalytiCalc takes a guess as to whether that text is just text  or  a
  1143.  number  to compute.  If the text contains any of the characters (, +,
  1144.  -, ., or [, it is assumed to be a formula, and the cell is marked  as
  1145.  containing  a  computable formula.  Otherwise it is just treated as a
  1146.  label and the formula itself is displayed.  If you find the guess  is
  1147.  not  to  your  liking, the DF command below lets you alter the format
  1148.  and tell AnalytiCalc that the entry is / is not a numeric.  An  addi-
  1149.  tional  special  character  is  the '"' (double quote) character.  If
  1150.  this character appears any- where in the entered formula, AnalytiCalc
  1151.  will  take the formula as text, regardless of whatever else is in it.
  1152.  You can also combine comments and formulas by using a separate state-
  1153.  ment and the *C construct 
  1154.  (e.g.  SUM[A3:A12]\SQRT(%)\*C SQUARE ROOT OF THE LENGTHS) 
  1155.  of  Calc.  Once a cell is set up as numeric or text, it remains as it
  1156.  was originally set until changed (using  the  DF  command,  described
  1157.  below).   The  ET and E" forms of the Enter command force the expres-
  1158.  sion to be entered as non computable so that it is  displayed  rather
  1159.  than  computed.   The EV form forces it to be computed, regardless of
  1160.  whether any special characters exist.  Numbers MUST have decimals  to
  1161.  compute  properly however.  Thus "EV 45" is INCORRECT, where "EV 45."
  1162.  is CORRECT (assuming you want the value 45.   to  be  computed;   the
  1163.  first will not).  If the decimals are omitted, the expressions may be
  1164.  considered integer.  These will be converted, but the conversion  has
  1165.  some  limitations  and  is  advised  against.  Also, integer division
  1166.  truncates results to produce an integer result  (so  that  7/2  would
  1167.  evaluate  to  3,  while  7./2.   would evaluate to 3.5, for example).
  1168.  Thus, to avoid surprises, use decimals.  
  1169.  
  1170.       Commands  will  be translated to upper case unless a " character
  1171.  appears anywhere in the command.  If a " character is found, only the
  1172.  first 2 characters are converted.  
  1173.  
  1174.       On  the PDP11 or VAX, AnalytiCalc will turn the auxiliary keypad
  1175.  feature of a VT100 on to allow use  of  the  auxiliary  keypad  as  a
  1176.  shorthand  for  many  user-specifiable  command sequences.  On MS-DOS
  1177.  machines, the ANSI.SYS driver (V2 and later) may be used  to  control
  1178.  display.  It may also be used (and is set up by typing AUXKPD.TXT) to
  1179.  define function keys.  This allows ANSI.SYS to be preset  to  perform
  1180.  keypad  functions.   A large version of ANSI.SYS, called BIGANSI.SYS,
  1181.  
  1182. AnalytiCalc Reference Manual                                   Page 24
  1183.  
  1184.  
  1185.  
  1186.  is provided with the AnalytiCalc kit.  This is needed to  handle  the
  1187.  keypad redefinitions provided.  
  1188.  
  1189.       Most  keys map to indirect files to make customizing AnalytiCalc
  1190.  easier.  These files must be in your current MSDOS  directory  to  be
  1191.  found  (or a path search utility must be used).  The system help file
  1192.  is called PCCHELP.HLP and must also be in your current  directory  to
  1193.  enable  the  HELP  command  to  work.   However,  where filenames are
  1194.  prompted for, AnalytiCalc can accept full MSDOS V2 pathnames.  If the
  1195.  program  cannot  open  a file for reading which is requested, it will
  1196.  attempt to create an empty file (and warn you of this on the top line
  1197.  of  the  screen).   Note that a "path extender" is generally packaged
  1198.  with AnalytiCalc on 8088 to allow the help file to be in  a  separate
  1199.  place however.  
  1200.  
  1201.       Within  command  files,  it is sensible to permit entry from the
  1202.  console of commands after prompts.  Therefore the % command has  been
  1203.  added  to  facilitate  such entry.  There is an alternative method of
  1204.  handling prompts (the "-" command) but  this  one  is  somewhat  more
  1205.  flexible.   You  will find examples of this in some of the .CMD files
  1206.  supplied with AnalytiCalc, and may use it in  your  own  if  desired.
  1207.  The  operation  is  as  follows:  a line beginning in % is assumed to
  1208.  have several fields:  
  1209.  
  1210.  %FLD-1%FLD-2%FLD-3 
  1211.  
  1212.  in  which  FLD-1  if  present is typed out to the screen first.  Then
  1213.  FLD-2 is passed as the command.  If FLD-3 exists and starts with a  ?
  1214.  or  \, then the terminal is read and the result is added onto the end
  1215.  of FLD-2 before the command is passed back to the spread  sheet.   If
  1216.  the  command begins with a space or control character or a \, then it
  1217.  is commented out and the command file falls  past  the  %  line.   If
  1218.  however FLD-3 started with ? and the initial read-in character is not
  1219.  \ or a control character, the command file is rewound.  This  feature
  1220.  is  used  in  the enter command file (AKD.CMD) to implement an "enter
  1221.  mode" somewhat akin to that of Visicalc, Supercalc, or others of that
  1222.  ilk  by  automatically inserting the "E " of the PortaCalc Enter com-
  1223.  mand until a \ is seen.  If FLD-3 should be present and start with  a
  1224.  &  character,  the  auxiliary  file is closed there and console input
  1225.  done as in \ input.  (Note that a control-Z may be used to  terminate
  1226.  Enter  mode  also,  and  F9  is  preset  to terminate it.) This func-
  1227.  tionality is probably less convenient than just using the /;  command
  1228.  to  go  into "enter-mostly" mode now, and should probably be ignored.
  1229.  It is handy in templates to be used by novices though, since it gives
  1230.  extremely easy console data entry in a controlled fashion.  
  1231.  
  1232. AnalytiCalc Reference Manual                                   Page 25
  1233.  
  1234.  
  1235.  
  1236.                                Examples
  1237.  
  1238.       The expressions that are entered can be numbers or formulas  re-
  1239.  lating  numbers  and  other  cells.  They may also consist of several
  1240.  statements separated by a \ character which will all be evaluated  at
  1241.  that cell, up to 110 characters.  Thus, valid commands might be 
  1242.  
  1243.    E 55.234      Enters value 55.234 at current cell
  1244.    E B4+H2+D5    Cell will contain the sum of cells B4,H2,
  1245.                  and D5.
  1246.    E Totals      Cell contains literal text "Totals".
  1247.  
  1248.                                FORMULAS
  1249.  
  1250.       Formulas  may  be used too.  These include 2 classes.  The first
  1251.  are the multi-argument functions, which either appear at the start of
  1252.  their  statements  or  substatements  (alone), or inside expressions.
  1253.  The difference between the classes is that  the  multiargument  func-
  1254.  tions  must  have  cell NAMES or RANGES as their arguments, while the
  1255.  single argument functions can have arbitrary Expressions in their ar-
  1256.  guments.   Otherwise they may mix freely.  All functions listed below
  1257.  may appear in command files or cells, and arguments  must  be  cells,
  1258.  not  expressions or constants.  The IF statement, while it is treated
  1259.  as a function syntactically, may NOT appear  inside  general  expres-
  1260.  sions,  but  must begin a cell equation or sub-equation (i.e., it may
  1261.  begin after a \ in a cell containing several operations).  It  cannot
  1262.  be  used inside command files driving cells, but its functionality is
  1263.  supplied there by the "*J label" function, so no real limitation  ex-
  1264.  ists on capability.  
  1265.  
  1266.  The available multiple argument functions are:  
  1267.  
  1268. AnalytiCalc Reference Manual                                   Page 26
  1269.  
  1270.  
  1271.  
  1272.    SUM[variables]     Sum of all arguments
  1273.    MAX[variables]     Max of arguments
  1274.    MIN[variables]     Min of arguments
  1275.    AVG[variables]     Average of arguments
  1276.    AVE[variables]     Average of arguments ignoring cells
  1277.                       containing 0.0 (e.g., labels)
  1278.    STD[variables]     Standard deviation squared
  1279.    IF [V1.rel.V2] statement | else-statement
  1280.    AND[variables]     Boolean AND of all variables in list
  1281.    IOR[variables]     Boolean inclusive OR of variables
  1282.    NOT[variable]      Boolean complement of variable
  1283.    XOR[v1,v2]         Boolean exclusive OR of v1,v2
  1284.    EQV[V1,V2]         Boolean "equivalence" of V1,V2
  1285.                       (complement of exclusive OR, true if
  1286.                       bits have the SAME value)
  1287.    CNT[variables]     Number of nonzero variables in list
  1288.    MOD[V1,V2]         Returns V1 modulo V2 (i.e., remainder
  1289.                       of V1/V2 division.)
  1290.    SGN[v1]            Returns 1.0 times sign of V1
  1291.    LKP[var,variables] Lookup variable in "variables" range
  1292.                       greater or equal to var, return its
  1293.                       index (starting with 0) into variables
  1294.                       range.
  1295.    LKN[var,variables] Lookup variable in "variables" range
  1296.                       less than or equal to var, return its
  1297.                       index (starting with 0) into variables
  1298.                       range.
  1299.    LKE[var,variables] Lookup variable in "variables" range
  1300.                       strictly equal to var, return its index
  1301.                       (starting with 0) into range. Note all
  1302.                       LKP, LKN, LKE return the last variable
  1303.                       index if no satisfactory value found.
  1304.    NPV[disc,vars]     Net Present Value of vars (equal time
  1305.                       interval numbers), at discount rate
  1306.                       disc where disc is a fraction
  1307.                       (e.g., .12 for 12%). Be sure the arguments
  1308.                       are all cells, not literals, including the
  1309.                       disc argument. Set a cell to the fraction
  1310.                       desired for the disc argument and use its
  1311.                       name in the arguments to NPV, rather than
  1312.                       attempting to use a literal (e.g., 0.12)
  1313.                       directly.
  1314.    IRR[PV,FV,returns] Internal Rate of Return. Will compute
  1315.                       internal rate of return on up to 20
  1316.                       periods, returning rate per period.
  1317.                       The returns are expected to be at
  1318.                       equal time intervals. PV and FV are
  1319.                       initial and final values of investment
  1320.                       and the result is computed via Newton
  1321.                       approximation. As with all functions here,
  1322.  
  1323. AnalytiCalc Reference Manual                                   Page 27
  1324.  
  1325.  
  1326.  
  1327.                       be sure all arguments are cell names, not
  1328.                       literal numbers.
  1329.    PMT[princ,inter,nper] Payment function. Generates payment
  1330.                       given principal amount, interest per
  1331.                       period (as a fraction), and number of
  1332.                       periods.
  1333.    PVL[pmt,inter,nper] Present Value function. Generates present
  1334.                       value of a loan given payment amount, 
  1335.                       interest rate, and number of periods.
  1336.                       All financial functions assume that
  1337.                       payments are for equal time intervals.
  1338.    RND[V1]            Random number. Generates a random number
  1339.                       distributed uniformly in the interval
  1340.                       0.0 to 1.0. An argument is required but
  1341.                       never touched.
  1342.  
  1343.  In  all  cases  except  IF, arguments are variable names separated by
  1344.  commas, or variable ranges, or mixtures separated by  columns.   Note
  1345.  too  that  ALL  THESE  FUNCTIONS  REQUIRE  CELLS  OR  ACCUMULATORS AS
  1346.  ARGUMENTS;  literals and single argument functions may  NOT  be  used
  1347.  here.   (That is why it is easy to place multiple commands on a line;
  1348.  the ACs or cells may be loaded in "separate" steps.) The IF [] state-
  1349.  ment  is a partial exception since a range may be used to replace ei-
  1350.  ther variable inside the []  condition  brackets.   The  sum  of  the
  1351.  ranges will be used in that case.  A possible IF statement might look
  1352.  like 
  1353.  
  1354.  IF [S2.LT.S5] R=2. | R=0.  
  1355.  
  1356.  The Boolean variables are computed by taking the  integer  values  of
  1357.  the  variables  and performing the appropriate boolean masking opera-
  1358.  tions on them.  The values are returned as whatever type (floating or
  1359.  integer)  the  cell is.  32 bit integers are used.  The CNT operation
  1360.  will (generally) omit cells that have  not  been  initialized,  since
  1361.  these  have a value of 0.0 and are not changed unless modified expli-
  1362.  citly.  It may be used to compute a more accurate  average  than  AVG
  1363.  where  many  uninitialized cells add zero values in.  The quotient of
  1364.  the SUM divided by the CNT of a range will give an average of nonzero
  1365.  cells  only.  The LKP function quickly locates a cell in a list where
  1366.  the value is in a desired range;  the *G function may be used to  ex-
  1367.  tract  other  cells  close  to the addressed cell (e.g., beside it or
  1368.  below it).  The LKN and LKE functions are exactly the same but search
  1369.  for lower or equal values instead of greater than values.  This makes
  1370.  varied search strategies easy to do.  These functions are most useful
  1371.  in  user  command files for selecting parts of the sheet according to
  1372.  criteria, as they allow very fast searches  of  large  parts  of  the
  1373.  spreadsheet  from  inside command files.  In this application the LKP
  1374.  class functions would be accessed via  the  TEst  command.   The  NPV
  1375.  function is the standard financial Net Present Value function, assum-
  1376.  ing the discount rate is the fractional interest percent  per  period
  1377.  
  1378. AnalytiCalc Reference Manual                                   Page 28
  1379.  
  1380.  
  1381.  
  1382.  for  the  amounts  in  the range given, and that the range of numbers
  1383.  represents equal time periods.  Remember to give  a  FRACTION  rather
  1384.  than  a  Percent, so a 5% interest rate per period should be given as
  1385.  .05 for example.  The IRR function will  compute  IRR  given  present
  1386.  value,  future  value, investments per period (for up to 20 periods),
  1387.  and assuming that the periods are equally spaced.  The IRR value  re-
  1388.  turned  is  per  period and must be multiplied by periods per year to
  1389.  get a yearly rate.  Note that other financial functions like PMT  may
  1390.  be  easily  obtained  by  simple  cell programs.  The RND function is
  1391.  provided to give random numbers.  This is useful  in  some  types  of
  1392.  Monte Carlo financial modelling.  If distributions other than uniform
  1393.  ones of random numbers are desired, they may be obtained via standard
  1394.  mathematical  transformations  from  this  uniform distribution.  The
  1395.  random number sequence is identical every  time  the  spreadsheet  is
  1396.  run.   BE  SURE  IN  USING  THESE FUNCTIONS THAT ALL ARGUMENTS ARE IN
  1397.  SPREADSHEET CELLS OR ACCUMULATORS.  LITERALS ARE NOT PERMITTED AS AR-
  1398.  GUMENTS.  Thus, a command like "SUM[A1:A5,5.5]" is illegal.  Instead,
  1399.  use a command like "A=5.5\SUM[A,A1:A5]" or "A=SUM[A1:A5]+5.5".  
  1400.  
  1401.       The  section on the interactive calculator (CALC) mode also men-
  1402.  tions the single argument functions available.  These include  normal
  1403.  trig  and  math functions like SQRT, SIN, COS, ATAN, AINT, ALOG, EXP,
  1404.  SINH, COSH, and some others.  These single argument functions may  be
  1405.  used  in  normal infix notation expressions, and do not have restric-
  1406.  tions on the types of arguments permitted them.  See the  section  on
  1407.  Calc  mode below for the full list.  There are also a large number of
  1408.  functions that are syntactically commands, but which perform calcula-
  1409.  tions.  These are also described in the Calc section and include date
  1410.  and matrix arithmetic and some addressing arithmetic functions.  
  1411.  
  1412.                             Variable Names
  1413.  
  1414.       A valid variable name might be H14 or N22 or A3, or the position
  1415.  independent forms P#n#m and D#n#m where n and m are offsets in Physi-
  1416.  cal or Display sheets from the current column and row.  A valid range
  1417.  is 2 variable names separated by colon (:).  Thus the range B2:B12 is
  1418.  valid  and  means  B2  through  B12  inclusive.  The range expression
  1419.  D#0#1:D#0#12 is also valid and means the cells on the  display  sheet
  1420.  in  the  same  column but 1 to 12 rows down from the current cell in-
  1421.  clusive.  (The displacements may be negative too, with - sign to  in-
  1422.  dicate  it,  as D#-3#2 for the display cell 3 columns left and 2 rows
  1423.  down from the current position.) The P# and  D#  forms  are  valuable
  1424.  since they work wherever you move them.  Other variables may be relo-
  1425.  cated when moved (renaming them to  correspond  to  their  new  loca-
  1426.  tions),  but  the P# and D# forms need never change and allow working
  1427.  with projections across the physical sheet in  various  ways.   There
  1428.  are a few restrictions with these forms.  They usually need to be en-
  1429.  closed in parentheses (e.g.  (P#3#5) rather than  P#3#5)  inside  ex-
  1430.  pressions.  For most purposes they do work interchangeably with other
  1431.  name schemes however, though the "normal" naming scheme is  generally
  1432.  
  1433. AnalytiCalc Reference Manual                                   Page 29
  1434.  
  1435.  
  1436.  
  1437.  easier to use.  Copying with relocation works with normal cell names,
  1438.  provided that the cursor is above and left of  cells  to  be  renamed
  1439.  (see  below).   The keypad copy command normally moves to A1 during a
  1440.  copy for this reason.  The D# forms do not always  work  in  the  ex-
  1441.  tended address areas of the sheet, depending on recalculation mode.  
  1442.  
  1443.       The special construction P#%ab or D#%ab allows relative address-
  1444.  ing relative to current physical or display location using  accumula-
  1445.  tors  named  a  or b (where a or b may be any accumulator name from A
  1446.  through Z but upper case is REQUIRED).  This computable relative  ad-
  1447.  dressing  affords  greater flexibility in command procedure construc-
  1448.  tion.  
  1449.  
  1450.       If a formula contains the construction {VN (where VN is any cell
  1451.  name), the FORMULA for cell VN is inserted  into  the  formula  being
  1452.  evaluated at that point, when the cell value is to be computed.  This
  1453.  may be done several levels deep, but is stopped after 10 translations
  1454.  to  avoid  infinite loops due to circular references.  Some care must
  1455.  be used here since the final  translated  formula  must  fit  in  110
  1456.  characters and will be truncated if it gets too long.  This construct
  1457.  is useful where formulas are to be tested.  These cell names may  (in
  1458.  AnalytiCalc  versions  for 320K and over) be replaced by alphanumeric
  1459.  names of your choice;  this will be  discussed  below.   The  formula
  1460.  replacement  feature provides a handy inline macro capability permit-
  1461.  ting complex formulas to be entered more easily.  This feature may be
  1462.  used  with the P#%ab form of addressing to provide runtime addressing
  1463.  of formulas anywhere in the matrix.  It may also be  used  (with  the
  1464.  position  relative P## forms of cell names) to conserve storage where
  1465.  a long formula must be repeated many  times,  at  the  cost  of  some
  1466.  speed.  
  1467.  
  1468.       The  command  processor may use these inline macros in commands.
  1469.  If a command line contains 2 successive underscores (__) anywhere  in
  1470.  its  length, the underscores will be stripped out of the command line
  1471.  and the command line will be scanned  for  {Vn  forms.   If  any  are
  1472.  found,  they  will  be substituted for prior to interpretation of the
  1473.  command.  This will occur AFTER any console text is read  if  console
  1474.  text  is required by one of the %%% forms of command line.  This per-
  1475.  mits formula cells to be used as a convenient place to  store  inter-
  1476.  mediate  answers  in models being driven by command files.  It is not
  1477.  particularly useful from the console, but works, and may be  used  to
  1478.  reenter  a  formula without moving it explicitly if there is a reason
  1479.  to do so.  (ENTER __{Vn).  
  1480.  
  1481. AnalytiCalc Reference Manual                                   Page 30
  1482.  
  1483.  
  1484.  
  1485.       Since  it is sometimes useful to have mixed formulas which allow
  1486.  certain cell references to be  absolute  and  never  relocated,  with
  1487.  other  references  which are relocatable, cell names may be specified
  1488.  absolute.  If the character "$" (dollar sign)  is  placed  after  the
  1489.  letter,  the number, or both, parts of the variable name, the part of
  1490.  the variable name followed by the dollar sign is absolute.  Thus, the
  1491.  variable  AB30 is relocatable in both row and column.  Variable AB$30
  1492.  is relocatable in row only (the 30 is not followed by $), and the  AB
  1493.  column  will not be changed in any relocate.  Variable AB30$ is relo-
  1494.  catable in column, but the row 30 reference does not  change.   Vari-
  1495.  able  AB$30$ is totally absolute.  Note that these absolute variables
  1496.  are harder to move around even on adding or deleting  rows,  so  they
  1497.  should  be  used  with  care.  This relocation protection can be tem-
  1498.  porarily inhibited with the OV + command and reinstated with the OV -
  1499.  command.   This  will  allow  copy  of cells with relocation if it is
  1500.  needed, without laborious editing.  The program starts in OV -  mode.
  1501.  If  the  OV + mode is set, the program will remain in OV + mode until
  1502.  OV - is set up again.  The commands may be given  in  the  form  OV-,
  1503.  OV -, OV+, or OV +.  
  1504.  
  1505.                             Variable Ranges
  1506.  
  1507.       Variable  ranges  must lie in a single row or column.  Erroneous
  1508.  specifications are rejected and ignored generally.  For  versions  of
  1509.  AnalytiCalc  supporting  matrix  operations,  matrix  dimensions  are
  1510.  however given by specifying the upper left and lower right corners of
  1511.  the  matrices.   Thus the range A1:B2 is the 2 by 2 matrix containing
  1512.  cells A1, A2, B1, and B2.  For operations using full rectangular  re-
  1513.  gions,  support  is offered via auxiliary keypad commands which allow
  1514.  filling of large regions or moving data into them.  This is done  via
  1515.  command  files  automatically invoked, but the methods used are tran-
  1516.  sparent to the user.  Other operations  on  rectangular  regions  not
  1517.  confined  to  a  single row or column may easily be added in the same
  1518.  way.  The internal implementation permits copying rows to columns and
  1519.  vice  versa  as well as rows to rows and columns to columns;  this is
  1520.  why regions must be one or the other.  It is  expected  that  regions
  1521.  are  specified starting at top left and ending at bottom right.  This
  1522.  must be done;  regions will not be completely handled otherwise.   By
  1523.  using  in-cell  loops  for their innermost computations, these macros
  1524.  are quite quick in execution and offer few  disadvantages.   They  do
  1525.  however ask separately for the bounds of the areas being modified.  
  1526.  
  1527.                           Function Arguments
  1528.  
  1529.       Note  that  the  square  brackets  ([])  are  needed  to delimit
  1530.  arguments in multiple argument functions.  The results  are  left  in
  1531.  accumulator  % and in the cell.  The IF form will compare 2 variables
  1532.  and execute either the statement or the  else-statement  (which  must
  1533.  NOT be another IF).  The valid relations are:  
  1534.        .EQ.    Equal
  1535.  
  1536. AnalytiCalc Reference Manual                                   Page 31
  1537.  
  1538.  
  1539.  
  1540.        .NE.    Not Equal
  1541.        .GT.    Greater than (V1 greater than V2)
  1542.        .LT.    Less than (V1 less than V2)
  1543.        .GE.    Greater than or Equal to (V1 >= V2)
  1544.        .LE.    Less than or Equal to (V1 =< V2)
  1545.  and  must  appear  in  this  form.   (Note  that  your  formulas must
  1546.  generally be in upper case only;  text can be anything.) 
  1547.  
  1548.                             Unary Functions
  1549.  
  1550.       The  second  class of formulas permit fully general arguments of
  1551.  expressions, cells, and the like (and are evaluated AFTER  the  multi
  1552.  argument  functions  lexically).   These  are  more conventional, use
  1553.  parentheses, and include single argument functions like  SQRT,  ALOG,
  1554.  EXP, SIN, COS, AINT, ABS, ATAN, and so on.  See the built in interac-
  1555.  tive calculator mode manual section below for more detail.   However,
  1556.  they  may  use variable names as anywhere, not just single letter ac-
  1557.  cumulators.  Thus, SQRT(A5) is a valid number.  There is  a  function
  1558.  list in the documentation of Calc mode later in this manual.  
  1559.  
  1560.                     Accumulators (Scratch Storage)
  1561.  
  1562.       The single letter accumulators of Calc mode (letters A through Z
  1563.  and %) are available globally and may take  on  all  Calc  mode  data
  1564.  types  (see  the  description  of calc mode below) including multiple
  1565.  precision.  They are usable globally on  the  entire  sheet  and  may
  1566.  serve as arguments to command files or return cells for results.  In-
  1567.  side command files, Calc mode can perform any of its  usual  calcula-
  1568.  tions.   The  multi-argument functions listed above are not available
  1569.  there (though they can be simulated by enumerating cells), but every-
  1570.  thing else is.  The letter accumulators are available in all cases in
  1571.  addition to cells.  Of course, any unused cell may be used as an  ac-
  1572.  cumulator  too, but cells in the spreadsheet are at most 8 bytes long
  1573.  and cannot hold multiple precision arguments.  
  1574.  
  1575.       To  get,  e.g.,  the square root of the sum of several variables
  1576.  (in a row or column;  ranges may only be in rows or columns together)
  1577.  one might have a formula line like:  
  1578.  
  1579.  SUM[A1:A20,B4,F2,C5:C20,J3:M3]\SQRT(%) 
  1580.  
  1581.  which  computes  the sum of the 2 cells and 3 ranges and leaves it in
  1582.  %, then computes the square root of that and leaves it in  the  cell.
  1583.  The  formulas  to  Calc may be complex but MUST NOT be longer than 78
  1584.  characters.  Break up longer ones so they  can  be  fed  to  Calc  in
  1585.  smaller  chunks.   Notice  that  the expression given could have been
  1586.  written as SQRT(SUM[A1:A20,B4,F2,C5:C20,J3:M3]) but was broken up for
  1587.  tutorial purposes.  
  1588.  
  1589.                    Auxiliary Commands and Functions
  1590.  
  1591. AnalytiCalc Reference Manual                                   Page 32
  1592.  
  1593.  
  1594.  
  1595.       The  commands  of  CALC  mode  should  be examined carefully for
  1596.  usefulness.  You can enter programs into CALC mode which can be  used
  1597.  as  user-defined  functions  from  the sheet if need be.  See the do-
  1598.  cumentation about the Calc mode  (interactive  calculator)  for  full
  1599.  lists of functions and further information.  
  1600.  
  1601.       Several  commands  available  in  cell calculations which affect
  1602.  computation exist;  several will be described here as well as in  the
  1603.  section on calc mode (which describes single cell calculation facili-
  1604.  ties in addition to those described here).  
  1605.  
  1606.       It  should  be  noted  that  these  functions  start  with the *
  1607.  character which also starts comments in command files to AnalytiCalc.
  1608.  Because  of this, the "Enter-mostly" mode treats any text that starts
  1609.  with * as a  comment.   To  enter  a  FORMULA  beginning  with  an  *
  1610.  character in "Enter-mostly" mode, you must use the syntax 
  1611.  
  1612.       /EV formula 
  1613.  
  1614.  where  formula  might  be  something  like  "*U IDATE"  (without  the
  1615.  quotes), i.e., something that may start with  a  *  character.   This
  1616.  method  allows  the  formula to be entered correctly.  Notice this is
  1617.  the "Command-mostly" command  for  entering  a  formula.   It  ALWAYS
  1618.  works, regardless of the type of formula.  
  1619.  
  1620.       One of these is the *G command.  Its syntax is 
  1621.  
  1622.  *G V1,V2 
  1623.  
  1624.  which  has the effect of evaluating variables V1 and V2 as column and
  1625.  row numbers on the physical sheet and returning  the  physical  sheet
  1626.  variable addressed by those variables.  The ranges are clamped to fit
  1627.  on the sheet.  This  gives  indirect  addressing,  permitting  lookup
  1628.  tables  to be made up by creating the index you want and then access-
  1629.  ing the addressed table element.  Typically the *G command  would  be
  1630.  the  last on a formula line, though it need not be.  Its value is re-
  1631.  turned in the % accumulator.  
  1632.  
  1633.       Another  is  the  *W command, which simply takes the number in %
  1634.  and places it in the formula for  the  current  cell  on  the  spread
  1635.  sheet.   This may be used to "freeze" a value, replacing a formula by
  1636.  a constant for future use.  Note that the previous  contents  of  the
  1637.  formula  entry  are  lost.  Thus, a *W command in the sheet will nor-
  1638.  mally cause itself to be overwritten after one use.   The  number  is
  1639.  stored in a format D35.24 in the worksheet.  
  1640.  
  1641.       To  implement  user functions, if Calc sees an expression of the
  1642.  form "*@filename.ext", it will execute that file as a command at that
  1643.  cell.   Any filename may be used and as many functions as desired can
  1644.  be handled in this way (with obvious overhead), with nesting depth of
  1645.  
  1646. AnalytiCalc Reference Manual                                   Page 33
  1647.  
  1648.  
  1649.  
  1650.  up  to  3  permitted.   These command files correspond to "macros" in
  1651.  other spreadsheets, and exist outside the sheet, so  a  command  file
  1652.  can be used by many worksheets.  
  1653.  
  1654.       AnalytiCalc  has also a command called *P which allows resetting
  1655.  of the physical coordinates while executing a  cell's  formulas,  FOR
  1656.  THE  DURATION  OF  THAT  CELL'S FORMULA ONLY or while in K mode (calc
  1657.  mode) only.  
  1658.  
  1659.       The  syntax  of  the  *P command is either just *P (which causes
  1660.  AnalytiCalc to prompt for column and row), or *P Variablename  (which
  1661.  moves   the   current   location  to  the  named  location),  or  *P@
  1662.  variable1,variable2 (which moves to the location which is defined  by
  1663.  variable 1 and 2 as col.  and row).  
  1664.  
  1665.       There  are  several  other useful calculation commands, a few of
  1666.  which are summarized here.  
  1667.  
  1668.       The command *F LABEL 
  1669.  will  evaluate  the  % variable.  If it is positive and nonzero, then
  1670.  the  current  input  line  will  be  rewound  and  the  program  will
  1671.  (silently)  seek a line of the form *CLABEL.  This allows loops to be
  1672.  defined with % as the counter.  This command acts on the unit used by
  1673.  the  AnalytiCalc @ command, NOT the unit for the Calc *@ command, and
  1674.  is a way that the Calc formula conditionals  may  be  reflected  back
  1675.  into  its  command  processing.   The TE expression command should be
  1676.  used first to set the % variable as needed to any arithmetic  expres-
  1677.  sion to control the loop.  
  1678.  
  1679.       The command *J LABEL 
  1680.  will  act as does *F LABEL but its search will be in the current file
  1681.  opened by a Calc *@ command (i.e., an *@file inside  a  cell  on  the
  1682.  sheet,  or  given  from  the console after a K command [see below] to
  1683.  enter bare interactive Calc).  
  1684.  
  1685.       The command *QF or *QW file ?searchkey?  <cc> 
  1686.  ("Query  Float" for getting a real ("floating point") number into the
  1687.  sheet from a file, or "Query Write" to write part of a file into  the
  1688.  sheet)  will  open file and look for lines starting with searchkey as
  1689.  given (with _ as a wild character).  Upon finding this, it will  look
  1690.  for  the <cc> and if it finds it, it will select the part of the line
  1691.  in the file between the 2 characters given (which may  be  alike)  as
  1692.  they  are  first  found, and will do one of 2 things.  If the command
  1693.  was *QF, then Calc will Float the value found  there  (attempting  to
  1694.  use  a  large  D format) and return it in %.  If the command was *QW,
  1695.  then Calc will Write the selected part of the record into the formula
  1696.  at  the current physical position on the sheet (which may be reset by
  1697.  an IMMEDIATELY PRECEDING *P command).  The  record  may  contain  the
  1698.  search  key anywhere.  It is up to the user to make sure the formulas
  1699.  copied make sense.  This however allows access to sequential files of
  1700.  
  1701. AnalytiCalc Reference Manual                                   Page 34
  1702.  
  1703.  
  1704.  
  1705.  data  which  can  be  created by an editor, word processor, etc., and
  1706.  which might hold keyed information that  the  spreadsheet  should  be
  1707.  able to manipulate.  As a user convenience, there may be a second key
  1708.  specified (also inside a pair of ?s).  If  two  keys  are  specified,
  1709.  Calc will search for and require that BOTH be somewhere in the record
  1710.  accepted.  Note too that the files opened may not  have  any  records
  1711.  longer  than 128 characters per line.  There are 2 variant forms, in-
  1712.  volving the 4th character (i.e., the next one after the F or W of *QF
  1713.  or  *QW).   These  may  permit sequential access to a data file.  The
  1714.  *QFK command is exactly like the *QF command (ditto *QWK and *QW) BUT
  1715.  it will not close the data file after finding the desired cell unless
  1716.  it reached EOF.  This permits subsequent commands of the *QFN command
  1717.  (for  "Next")  to  continue  reading the file.  The *QFN command will
  1718.  continue reading the file (the file spec must be  there  but  is  ig-
  1719.  nored) from the next record and will also not close the file.  (Ditto
  1720.  *QWN.) The *QFC command will act exactly as *QFN BUT will  close  the
  1721.  file  when  the request completes.  Thus, a file may be opened with a
  1722.  *QFK (or *QWK) command, subsequent data retrieved by  *QFN  commands,
  1723.  and  finally  the last data retrieved with a *QFC command.  Also, *QF
  1724.  commands will close the file prior to opening another.   The  command
  1725.  mnemonics here may be read as Query File [Next/Close/Keepopen].  
  1726.  
  1727.       Formulas entered may have the following constructs which will be
  1728.  edited into the formula as entered  (so  a  command  file  can  enter
  1729.  them):  
  1730.  
  1731.           _@V1,V2  Means  get  the  values stored in V1 and V2 and use
  1732.                them as column and row locations pointing at some  cell
  1733.                in  the  sheet.  Replace the construct with the name of
  1734.                that cell.  
  1735.           _#V1  Means take the real number in cell V1 and unpack it as
  1736.                if it had been a packed value from  a  formula  with  8
  1737.                characters packed;  then convert it back into ASCII and
  1738.                place in the formula in place of this construct.   This
  1739.                construct  is  intended  to  be  used with the *U STRVL
  1740.                function to allow retrieval and edit of formulas.   The
  1741.                *U XQTCM  function  permits use of the EDit command (as
  1742.                well as others) within a cell for string  manipulation.
  1743.                Only  8  characters  at  a time may be represented (the
  1744.                limit imposed by cell size), but  repeated  use  allows
  1745.                handling  any  desired length.  An application would be
  1746.                setting the cell used as V1 to a packed  representation
  1747.                of either of two strings inside an IF [] and then EDit-
  1748.                ing the string into the formula as desired where one of
  1749.                the  2 strings should be made to appear.  This capabil-
  1750.                ity is crude but provides the bare bones functionality.
  1751.                Additional  USRFCT calls to give simpler (but more ver-
  1752.                bose) string manipulations are  not  too  hard  to  add
  1753.                should the user need them.  
  1754.  
  1755.  
  1756. AnalytiCalc Reference Manual                                   Page 35
  1757.  
  1758.  
  1759.  
  1760.                             Formula Length
  1761.  
  1762.       Formulas have 109 characters allotted to them for use inside the
  1763.  spread sheet.  It may happen these are not enough for use.  In  other
  1764.  spreadsheets, the technique is to put the formulas in other cells in-
  1765.  side the sheet and possibly use screen windows to  avoid  display  of
  1766.  the intermediate results.  
  1767.  
  1768.       While  you can use that technique here too, you have an alterna-
  1769.  tive.  It is to use an indirect file in that cell and inside the cell
  1770.  in the spreadsheet just have a command "*@FILE.TYP" where the file is
  1771.  named "FILE.TYP" (you pick the real name).  Inside this file  may  be
  1772.  whatever calculations you like.  
  1773.  
  1774.       So  long  as  the file is to operate in a fixed cell location in
  1775.  your spreadsheet, you may use variable names like A3, D1,  etc.   in-
  1776.  side  the file.  Your command files may include any multiple argument
  1777.  functions except the IF function.  (The *F and *J  functions  can  be
  1778.  used   to  provide  equivalent  functionality  inside  command  files
  1779.  however.) The only restriction on multiple argument functions is that
  1780.  their arguments must be cells, not general expressions.  
  1781.  
  1782.       Once  you  add  or  delete  rows  or columns, or copy a formula,
  1783.  though, the file may not work as expected if the cell calling it  has
  1784.  moved.   Since  the  relocation  done by AnalytiCalc only operates on
  1785.  formulas stored directly in the spreadsheet, it cannot relocate vari-
  1786.  ables  in the indirect files.  However, you can make the files "posi-
  1787.  tion independent" so they WILL work wherever they  are  called  from.
  1788.  (This has the side benefit that a single file can be called from many
  1789.  cells.) 
  1790.  
  1791.       The  way  to  make  the  files  position  independent  is to use
  1792.  location-relative variable names instead of absolute ones.  That  is,
  1793.  inside  cell  B4, the cell immediately above can be named B3 (the AB-
  1794.  SOLUTE name), or it can be relocatably  named  P#0#-1  (the  relative
  1795.  name).   Likewise  the cell one to the right would be named either C3
  1796.  or P#1#0, and so on.  The cell two down and one left would be  either
  1797.  A5  or  P#-1#2 (you can begin to see how it goes).  A file containing
  1798.  only location-relative variable names will work even if called from a
  1799.  different  cell,  since the references will be figured out when used.
  1800.  These references are more difficult to write than the absolute  ones,
  1801.  but  since they work without renaming, they provide a level of flexi-
  1802.  bility needed where long formulas must be used.  These  forms  should
  1803.  be  used wherever indirect files are used to hold cell formulas.  The
  1804.  computed cell name forms like P#%ab can be used also provided  the  a
  1805.  and b accumulators are initialized properly, or the command file does
  1806.  its own relocation using the X and Y accumulators set on entry.  
  1807.  
  1808.       By using command files, it is possible to add your own functions
  1809.  to the spreadsheet.  Just devise a command  file  that  performs  the
  1810.  
  1811. AnalytiCalc Reference Manual                                   Page 36
  1812.  
  1813.  
  1814.  
  1815.  arithmetic  and addressing you need and use *@file.typ where you want
  1816.  to evaluate the function.  Arguments can be  passed  in  accumulators
  1817.  and  P## or D## forms can be used for cell addressing (note that it's
  1818.  P#col#row and D#col#row).  The *U HERE function can be used to return
  1819.  the current location in two accumulators to allow address arithmetic. 
  1820.  
  1821.                         Linking Multiple Sheets
  1822.  
  1823.       To  enhance  AnalytiCalc, it is possible to have a cell refer to
  1824.  cells from another, saved sheet anywhere in the  system.   The  sheet
  1825.  must  normally  have  been  saved NUMERICALLY (see PPN command below)
  1826.  starting at the upper left (i.e., cell A1) as would be the convention
  1827.  for using with ACGRAF, the associated graphics output utility.  
  1828.  
  1829.       The command *XV filename V1 
  1830.  will  eXtract  the  Value  of  cell V1 (V1 is any variable name, e.g.
  1831.  C15, AA3, F9, B34, etc.) from the saved sheet saved in filename.  The
  1832.  filename  is  any  legal host system file specifier.  Note that there
  1833.  may be as many files as desired here, but only one cell is returned. 
  1834.  
  1835.       If  it  is desired to extract a formula from a saved sheet saved
  1836.  NON-NUMERICALLY, the command form is 
  1837.  *XF filename V1 
  1838.  and  this will cause the formula in "filename"'s cell V1 to overwrite
  1839.  the current physical sheet.  To avoid this, one might write a formula
  1840.  like 
  1841.  
  1842.  *P V2 \*XF myfile.typ V1 
  1843.  
  1844.  which  would  cause  current  sheet  variable V2 to have its' formula
  1845.  loaded from saved sheet "myfile.typ"'s variable V1.   Note  too  that
  1846.  the GPR or GDR commands will load saved sheets onto the current sheet
  1847.  (starting at the cursor) with all formulas relocated, so that  entire
  1848.  saved  sheets  can  be merged quickly where the one by one operations
  1849.  just described would be too slow.  
  1850.  
  1851.       In  general, save your sheets symbolically (non-numerically) for
  1852.  archival purposes;  save numerically for post processing or  handling
  1853.  of  data  by  "master"  sheets or for graphics.  You may want to edit
  1854.  AUXKPD.TXT so that F4 saves the entire sheet  both  symbolically  and
  1855.  numerically  if you frequently do both and want the two to be in syn-
  1856.  chronism.  The default save, PPX, now saves both numbers  and  values
  1857.  so it is normally all that is needed.  
  1858.  
  1859.  
  1860.  
  1861. AnalytiCalc Reference Manual                                   Page 37
  1862.  
  1863.  
  1864.  
  1865.            Loading Non-AnalytiCalc text files onto the Sheet
  1866.  
  1867.        FILE LOADING
  1868.  
  1869.    F filename/nnnn      Read filename, skipping nnnn lines
  1870.                      if the "/nnnn" is there, and load
  1871.                      contents onto the currently displayed
  1872.                      screen, broken into columns as the
  1873.                      current screen is set up.
  1874.  
  1875.       This  command is designed to make it easy to load document files
  1876.  into AnalytiCalc in quasi-image mode.  Once  loaded,  the  characters
  1877.  are  in formula cells and may be moved around the sheet.  The display
  1878.  format must be reset to get them to be  treated  as  non-text;   this
  1879.  command  will  reset  all  loaded  cells  to text format display.  It
  1880.  repaints the screen upon loading.  This feature makes it easy to cap-
  1881.  ture data in AnalytiCalc from other unrelated programs.  You can com-
  1882.  pute with cells that are loaded in this way but contain valid numeric
  1883.  data  by  changing them to numeric cells by the DF range [*] command.
  1884.  If you need to add decimals to the end of  the  cells'  numbers,  the
  1885.  ED //./  command  will  add  a decimal to the end of a number and the
  1886.  ED / // command can be used to get rid of extra space characters in a
  1887.  formula.  
  1888.  
  1889.  
  1890.                   Getting Saved Sheet Data from Files
  1891.  
  1892.        RESTORING YOUR SPREADSHEET
  1893.  
  1894.      GD          Reload sheet down/right onto display
  1895.                  coordinates.
  1896.      GP          Reload sheet down/right onto physical
  1897.                  coordinates.
  1898.      GPR         Reload sheet onto physical coords and Relocate
  1899.                  formulas as if the saved A1 cell were moved
  1900.                  to the current cursor.
  1901.      GDR         Similar to GPR but on display coordinates.
  1902.      Gxx+        Add saved sheet (if default save) values
  1903.                  to current values; enters Recalc Manual mode.
  1904.      Gxx-        Subtract saved sheet (if default save) values
  1905.                  from current values. Also enters Recalc Manual
  1906.                  mode.
  1907.  
  1908.  
  1909.       The  GP/GD  commands  are  the inverse of the PP/PD commands and
  1910.  load those files to potentially new locations.  This  is  the  simple
  1911.  way  to  merge  sheets.  In these cases, you are separately asked for
  1912.  filenames and limits on what part of the sheets to  load/save.   Only
  1913.  cells  that  are  marked in use are saved, so sparse sheets take less
  1914.  space than saving the direct access files.   Note  that  on  save  or
  1915.  
  1916. AnalytiCalc Reference Manual                                   Page 38
  1917.  
  1918.  
  1919.  
  1920.  restore  the  ranges  to restore are asked for.  To restore the sheet
  1921.  starting at the cursor, specify the lowest row/column offset of 1 and
  1922.  the  highest either 0 or a very large number.  Any rectangular region
  1923.  can be restored by giving the X and Y coordinates of the  lowest  and
  1924.  highest  offsets from the upper left to restore, counting from 1.  If
  1925.  the P or D is omitted from the GPx or GDx commands (where x is either
  1926.  R  or  anything  else),  the action will be determined by whether the
  1927.  sheet was saved by a PP or by a  PDx  command.   REMEMBER:   THE  LOW
  1928.  OFFSET SHOULD BE 1 OR LARGER, NOT 0.  
  1929.  
  1930.       The  GPR  or  GDR commands relocate a saved sheet to a new loca-
  1931.  tion.  If for example a sheet is saved from A1 on down and right,  if
  1932.  it  is  loaded into another sheet when the cursor is at another cell,
  1933.  all formulas are relocated on load so that they are correct  for  the
  1934.  new  location.   (This follows the normal relocation control rules so
  1935.  that the $ forms of names may inhibit relocation.) The intent of this
  1936.  is that it makes it trivial to merge multiple sheets and make summary
  1937.  sheets.  
  1938.  
  1939.       In  AnalytiCalc/PC,  the logic to write to cells involves checks
  1940.  of the built in symbol table to ensure that cells are not  previously
  1941.  there  and needing to be replaced.  This slows the Get operation con-
  1942.  siderably, and is normally bypassed.  However, where a saved sheet is
  1943.  being  merged  into  an  existing sheet (rather than restoring into a
  1944.  previously empty region of the sheet), the full logic may  be  needed
  1945.  for  correct  operation.   To  get it, enter the filename followed by
  1946.  "/M" (so that to read SAVESHEET.PCC in the full-update mode you reply
  1947.  SAVESHEET.PCC/M  to  the  "Enter Filename>"  prompt, rather than just
  1948.  SAVESHEET.PCC, as an example.) (M stands for Merge.) 
  1949.  
  1950.       The  +  or - modifiers in the 4th character of the command allow
  1951.  you to add or subtract multiple saved sheet  values.   These  require
  1952.  that the normal default save (which includes both numeric and formula
  1953.  data) have been done to save the sheets being added.  The  values  in
  1954.  the sheet have the saved values either added (if +) or subtracted (if
  1955.  -) from the current values.  The manual recalculation flag is set  to
  1956.  prevent  any automatic recalculations also, since formulas are loaded
  1957.  from the last sheet loaded and overwrite other formulas in  the  same
  1958.  cells.  (This is generally not a problem.) To manipulate these values
  1959.  if there is a need to, the TEst command and the matrix math functions
  1960.  (which  include  multiply  matrix  by constant) allow two dimensional
  1961.  areas to be moved around or multiplied by constants  without  turning
  1962.  on  the  sheet recalculation.  Thus, averaging 4 sheets could be done
  1963.  by a GP command, three GPx+ commands, and then  a  TE  using  the  *U
  1964.  MMPYC function to multiply the whole area by 0.25.  (One could use TE
  1965.  A=0.25 to get a "cell" A0 to use in the MMPYC  function  if  no  0.25
  1966.  value existed to use already.) 
  1967.  
  1968.  
  1969.  
  1970. AnalytiCalc Reference Manual                                   Page 39
  1971.  
  1972.  
  1973.  
  1974.                       The AnalytiCalc HELP System
  1975.  
  1976.          HELP
  1977.  
  1978.       Hn     Display a screen of help. (n from 0 thru 9)
  1979.  
  1980.       The  H command will display a screenful of help giving a summary
  1981.  of many AnalytiCalc commands and syntax options.   When  you  type  a
  1982.  second return, it will redraw the screen.  
  1983.  
  1984.       The F1 key also means 'Help', and the ALT-F1 key draws a diagram
  1985.  of the function key assignments.  Control F1 will  draw  a  one  line
  1986.  reminder HELP message on line 25.  
  1987.  
  1988.       There are multiple help pages.  They are selected by commands H0
  1989.  through H99, the number defaulting to  0  and  selecting  which  help
  1990.  screen will appear.  
  1991.  
  1992.  
  1993.                   MOVING TO LOCATION (GOTO anywhere)
  1994.  
  1995.        LOCATE CURSOR (GOTO somewhere on the sheet)
  1996.  
  1997.     L variable-name    Position cursor at variable-name
  1998.  
  1999.  
  2000.       The  L  command moves the current position to the variable named
  2001.  on the Physical sheet (and the display sheet if the  variable  is  on
  2002.  the display).  Examples might be SKIP 1 
  2003.      L B3    Move to cell B3 
  2004.      L D6    Move to cell D6 
  2005.  
  2006.  
  2007.  
  2008. AnalytiCalc Reference Manual                                   Page 40
  2009.  
  2010.  
  2011.  
  2012.        Setting Direction for Motion after Entering Cell Contents
  2013.  
  2014.        MOTION DIRECTION (Set Default
  2015.        Direction to move after an Enter)
  2016.  
  2017.      THIS COMMAND SETS DIRECTIONS FOR AUTOMATIC
  2018.           MOTION AFTER ENTER ONLY.
  2019.      SEE BELOW FOR HOW TO MOVE THE CURSOR AT
  2020.           OTHER TIMES.
  2021.  
  2022.        M0           (Restore last auto move direction)
  2023.        M1           (Move up)
  2024.        M2           (Move down)
  2025.        M3           (Move left)
  2026.        M4           (Move right)
  2027.        M5           (No auto motion)
  2028.  
  2029.  
  2030.       The  M command causes automatic cursor motion after an E command
  2031.  in the direction indicated.  This only occurs  after  an  E  command.
  2032.  The  default  condition is not to move at all after an E command, and
  2033.  this may be reestablished by a command of form M5 (actually Mc, where
  2034.  c  is  any  character other than 1 to 4.) The M0 command restores the
  2035.  last automatic motion direction and saves the current one as the  new
  2036.  last  direction.   This  is useful where a command procedure needs to
  2037.  turn off auto motion but wants to turn it back  on  at  the  end;   a
  2038.  dummy EDit may be used if a single motion is needed.  
  2039.  
  2040.  
  2041.                  Including Multiple Files into Reports
  2042.  
  2043.        MS   Macrocell Show (handles &% and &&% files)
  2044.        MH   Macrocell Hide (no special & treatment)
  2045.        &%file,nskip,nshow    overlay file on screen
  2046.        &&%file,snskip,nshow  Include file for output
  2047.  
  2048.       The MS and MH commands turn on or off the handling as print time
  2049.  macros of the &% and &&% forms of filenames.  These permit you to use
  2050.  AnalytiCalc  for  report  generation or outline handling more easily.
  2051.  In MS mode, if a cell has an &%file form in it,  that  file  is  read
  2052.  when  that  cell is displayed.  The first "nskip" records are skipped
  2053.  in the file, and up to "nshow" lines of the  file  are  displayed  on
  2054.  null  cells  of the spreadsheet.  Up to 4 files may be open at a time
  2055.  here.  The left margin of the file text is made to coincide with  the
  2056.  location  of  the  cell  containing the reference.  You can use the $
  2057.  (spawn) command to edit these files with your favorite editor or word
  2058.  processor  on  the  system  and they will automatically be updated on
  2059.  screen.  The &&% form is used to include (possibly lengthy) files  in
  2060.  output.   The  files  are included in spreadsheet output at the point
  2061.  they are seen, indented by the amount of the  indenting  of  the  &&%
  2062.  
  2063. AnalytiCalc Reference Manual                                   Page 41
  2064.  
  2065.  
  2066.  
  2067.  command  form.  Therefore, you can use AnalytiCalc to organize a mul-
  2068.  tilevel hierarchy of printout of reports.  If a &&% form is  seen  in
  2069.  one  of  the  files being included, that file is opened and included.
  2070.  This nesting may go to a depth of 4  levels.   This  permits  a  real
  2071.  "frame  editing"  using  AnalytiCalc and your favorite editor or word
  2072.  processor (WITHOUT requiring you to learn yet another editor.) 
  2073.  
  2074.       In  general,  AnalytiCalc  is  not  supplied with a text editor.
  2075.  Most people will already have one and it was thought a waste of  time
  2076.  to  ask  anyone  to learn another.  Rather, the program allows you to
  2077.  use whatever editor you like (via the $ or } commands  to  exec  your
  2078.  own  editor) even under the sheet.  What is added is rather the abil-
  2079.  ity to ORGANIZE documents flexibly and  easily.   AnalytiCalc  graphs
  2080.  also  are  written  in a format that permits this treatment.  Because
  2081.  AnalytiCalc uses DOS to do its console  writes,  it  will  also  work
  2082.  within most or all windowing systems in an orderly way.  (Maybe some-
  2083.  day DOS will be faster...).  A console mode ("View IBM") is  provided
  2084.  which  uses  the  IBM BIOS for its screen handling, but this does not
  2085.  gain much speed over the DOS driver and will be useful in only a  few
  2086.  situations.   When  using  the  DOS  modes, this BIOS dependency will
  2087.  never cause problems.  
  2088.  
  2089.  
  2090.                    Resetting Displayed Part of Sheet
  2091.                        (Windowing and Scrolling)
  2092.  
  2093.          ORIGIN RESET  (Windows onto physical sheet)
  2094.  
  2095.      OA variable   Reset origin of display to variable
  2096.      OR variable   Reset display down and right to start
  2097.                        with variable
  2098.      OAD variable   Reset origin of display to variable
  2099.                        leaving windows intact.
  2100.      ORD variable   Reset display down and right to start
  2101.                        with variable leaving windows
  2102.                        intact.
  2103.  
  2104.  
  2105.       The  OA and OR commands let you do quick scrolls around the phy-
  2106.  sical sheet by resetting the upper left corner of the  display  sheet
  2107.  to point at any variable on the physical one and make the rest follow
  2108.  suit (OA), or will reset the display sheet starting at  your  current
  2109.  cursor  location to point at the physical sheet variable and make all
  2110.  parts of the displayed sheet down and right from your  current  loca-
  2111.  tion correspond likewise.  
  2112.  
  2113.       Thus, if you start with a normal initial display and execute the
  2114.  commands 
  2115.  
  2116.      L C1 
  2117.  
  2118. AnalytiCalc Reference Manual                                   Page 42
  2119.  
  2120.  
  2121.  
  2122.      OR H1 
  2123.  
  2124.  you wind up with columns A and B still on screen, but now the remain-
  2125.  ing columns are H, I, J, K, L instead of C, D, E,  F,  and  G.   This
  2126.  happened  because cell H1, down and right were pointed to by the dis-
  2127.  play sheet starting where you were, which was cell C1, initially  the
  2128.  3rd column and first row.  Had the command been OA H1, the column la-
  2129.  bels would be H-N rather than the initial A-G.  
  2130.  
  2131.       If  the  OAD  or ORD forms are used, the area remapped is simply
  2132.  moved by the offset between the  old  origin  of  the  region  you're
  2133.  remapping  and  the  new origin, so windows stay relatively placed as
  2134.  they were.  Scrolling now uses OAD and ORD forms so windows stay  in-
  2135.  tact.  
  2136.  
  2137.       The  difference  between OA, OAD, OR, and ORD may be illustrated
  2138.  in the following figures, which represent the screen mapping after  a
  2139.  command sequence 
  2140.  
  2141.     OA A1
  2142.     L C1
  2143.     OR AA1
  2144.     L A11
  2145.     OR A100
  2146.  
  2147.  which  produces  a  screen mapping like this:  (note only part of the
  2148.  map is reproduced...) 
  2149.  
  2150.           A       B       AA       AB      AC
  2151.     1>   A1      B1      AA1      AB1     AC1
  2152.     2>   A2      B2      AA2      AB2     AC2
  2153.     3>   .       .       .        .       .
  2154.     4>   .       .       .        .       .
  2155.     5>   .       .       .        .       .
  2156.     6>
  2157.     7>
  2158.     8>
  2159.     9>
  2160.    10>  A10     B10    AA10      AB10     AC10
  2161.   100> A100    B100    C100      D100     E100
  2162.   101> A101    B101    C101      D101     E101
  2163.   102>
  2164.   103>
  2165.   104>        and so forth. Note that columns
  2166.   105>           AA, AB, and AC are now mapped
  2167.   106>           for only 10 rows. Thus we have
  2168.   107>           3 screen regions, not 4.
  2169.  
  2170.  
  2171.  While after a sequence like:  
  2172.  
  2173. AnalytiCalc Reference Manual                                   Page 43
  2174.  
  2175.  
  2176.  
  2177.     OA A1
  2178.     L C1
  2179.     OR AA1
  2180.     L A11
  2181.     ORD A100
  2182.  
  2183.  the resulting screen mapping looks more like this:  
  2184.  
  2185.           A       B       AA       AB      AC
  2186.     1>   A1      B1      AA1      AB1     AC1
  2187.     2>   A2      B2      AA2      AB2     AC2
  2188.     3>   .       .       .        .       .
  2189.     4>   .       .       .        .       .
  2190.     5>   .       .       .        .       .
  2191.     6>
  2192.     7>
  2193.     8>
  2194.     9>
  2195.    10>  A10     B10    AA10      AB10     AC10
  2196.   100> A100    B100   AA100     AB100    AC100
  2197.   101> A101    B101   AA101     AB101    AC101
  2198.   102>
  2199.   103>
  2200.   104>        and so forth. Note that columns
  2201.   105>           AA, AB, and AC now extend to
  2202.   106>           the full screen. This gives
  2203.   107>           4 screen regions.
  2204.  
  2205.  
  2206.  
  2207.       These  figures illustrate the usefulness of the OAD and ORD com-
  2208.  mands.  
  2209.  
  2210.  
  2211.  
  2212. AnalytiCalc Reference Manual                                   Page 44
  2213.  
  2214.  
  2215.  
  2216.                          Putting Data to Files
  2217.  
  2218.          SAVING YOUR SPREADSHEET
  2219.  
  2220.      PD        Put out current Display sheet (Formulas)
  2221.      PP        Put out current Physical sheet (Formulas)
  2222.      PDN       Put out current Display sheet (Numbers)
  2223.      PPN       Put out current Physical sheet (Numbers)
  2224.      S         Startup questions. Allows global width
  2225.                and format settings and new title entry.
  2226.  
  2227.  
  2228.       The  S  command will lead to questions being asked about whether
  2229.  to update the display mapping.  If you reply Y, you will be  able  to
  2230.  reset the default display column width to whatever you like between 1
  2231.  and 120 characters and to say whether to reset the display  sheet  to
  2232.  point to the upper left of the physical spreadsheet.  In any case you
  2233.  will be able to reset the default format and the  spreadsheet  title.
  2234.  In AnalytiCalc-88, this is all the S command does.  
  2235.  
  2236.       The  PD  and  PP  commands write Display or Physical sheet cells
  2237.  that are active to a specially formatted sequential ASCII text  file,
  2238.  always  starting  from  the current position of the cursor and saving
  2239.  right and down.  Some questions will be asked so you may enter a max-
  2240.  imum displacement to save (so not all of a large sheet need be saved)
  2241.  in columns and rows.  On reload (the GP/GD commands), these questions
  2242.  are also asked, and minimum displacements are asked also to allow you
  2243.  to enter basically any region of the saved sheets  into  the  current
  2244.  sheet  starting  at  the  current location and moving down and right.
  2245.  This gives a large scale move capability and a sheet  merge  capabil-
  2246.  ity.  
  2247.  
  2248.       The  PPN  and  PDN  commands  save numbers instead of formats to
  2249.  permit loading of isolated numeric values from other sheets by  using
  2250.  the GD or GP commands (below).  They record only numbers and not for-
  2251.  mulas, but this allows any cell's numeric value from other sheets  to
  2252.  be loaded into another sheet without loading all formulas and repeat-
  2253.  ing calculations.  Also, the PPN/PDN commands are needed to  use  the
  2254.  ACGRAF  program  to  graph parts of a sheet if this form of output is
  2255.  desired.  
  2256.  
  2257.       The  PP/PD  commands are suitable for archival storage of spread
  2258.  sheet data, or for its transportation to  differently  compiled  ver-
  2259.  sions of AnalytiCalc.  
  2260.  
  2261.  
  2262.  
  2263. AnalytiCalc Reference Manual                                   Page 45
  2264.  
  2265.  
  2266.  
  2267.                          Recalculation Control
  2268.  
  2269.        RECALCULATE
  2270.    R    Recalculate all of the sheet.
  2271.    RM   Recalculate manually only until R command given
  2272.    RE   Recalculate Entries as made but nothing else until
  2273.           R command given.
  2274.    RI   Recalculate Incremental - Calculate displayed cells only.
  2275.    RM   Recalculate manually only until R command given
  2276.    RAF  Recalculate sheet, without constant recalculation
  2277.    RF   Recalculate, Force constant recalculation.
  2278.    RR   Recalculate, Force, but stay in RE or RI mode if in
  2279.           it already.
  2280.  
  2281.  
  2282.       The  R  command  forces a recalculation of the sheet.  This will
  2283.  evaluate all formulas on the sheet and update the display to show the
  2284.  new  numbers.   Normally,  recalculation is done after each number is
  2285.  entered to update the new cell, but the RF command forces  total  re-
  2286.  calculation  in  case anything was missed.  The standard keypad's Re-
  2287.  calculate key generates the RAF command  automatically  for  ease  of
  2288.  use.  
  2289.  
  2290.       Since these calculations can be time-consuming, you can suppress
  2291.  them while doing  input  by  entering  the  RM  command  (Recalculate
  2292.  Manually)  which  suppresses  recalculation until an R command is en-
  2293.  tered.  This command's format is just 
  2294.  
  2295.  RM 
  2296.  
  2297.  
  2298.       For  further speedups, AnalytiCalc can be put into RE or RI mode
  2299.  to recompute only the cells just entered after each entry, or to com-
  2300.  pute  cells  on  the  display only.  It starts in RI (Recalculate In-
  2301.  cremental) mode until an R command  is  given.   After  an  R  or  RF
  2302.  command  is given, AnalytiCalc goes into a mode where it will compute
  2303.  ALL cells that have anything in them  at  each  sheet  recomputation.
  2304.  Another  RI  or  RE command will return to the previous mode.  The RR
  2305.  command does a RF (Recalculate,  Force  constant  recomputation)  but
  2306.  stays  in Incremental or Entry mode.  Whenever a new sheet is loaded,
  2307.  a single R is done automatically regardless of the current mode.  
  2308.  
  2309.       To  speed  normal  recalculation, AnalytiCalc only computes con-
  2310.  stants once.  The normal RF command will force them to be  recomputed
  2311.  also.   AnalytiCalc  normally  will  keep  track  of  the  lowest and
  2312.  furthest right cells in use and only ever try to recompute cells that
  2313.  have active values there.  
  2314.  
  2315.  
  2316.  
  2317. AnalytiCalc Reference Manual                                   Page 46
  2318.  
  2319.  
  2320.  
  2321.                       Setting Relocation Boundary
  2322.  
  2323.       RELOCATE BOUNDARY
  2324.  
  2325.          RB*     Set maximum row and col for relocation
  2326.                  to end of sheet
  2327.          RB Var  Set maximum row and col to be relocated
  2328.                  to coords of Var (cell name)
  2329.  
  2330.       The  RB command affords a way to specify a lower right corner to
  2331.  the area relocated by any of the copy and relocate operations.  Below
  2332.  or  to the right of the relocation boundary, moves are all treated as
  2333.  absolute even if specified as relative.   Therefore  the  area  below
  2334.  this boundary will not be relocated by the AR commands or the CR com-
  2335.  mands.  This allows the AR operation to relocate only a  finite  max-
  2336.  imum  number  of  rows  or columns, or permits cells moved beyond the
  2337.  boundary specified to be unrelocated.  The upper left corner  of  the
  2338.  relocation  area  is  defined by the cursor position, so this permits
  2339.  any rectangular area to be moved without relocation while the rest is
  2340.  relocated.   Combination  of this feature with the AR and CR commands
  2341.  permits moving rows or columns (or parts of them) via command  files.
  2342.  This moving would generally be done with the IR command to relocate a
  2343.  region in place to be moved to another site, then actually copying it
  2344.  (absolutely) to the desired destination.  Alternatively, the AR/AA/CR
  2345.  commands can be used to move things around.  For example, a rectangle
  2346.  could  be  moved away from the origin further by using the cursor and
  2347.  the RB command to delimit the area to move, then using a command file
  2348.  to  cycle  through  a  set  of CR commands to copy all cells down the
  2349.  desired amount.  The AA command could then be used to delete the  un-
  2350.  desired top cells and the area to be moved now moved into its new ad-
  2351.  dress, all other cells having been relocated.  The  functionality  of
  2352.  moving  cells is however much better served on AnalytiCalc by the OA,
  2353.  OR, and DL commands to reset the display mapping (possibly while log-
  2354.  ging  keystrokes  so  the mapping can be easily reproduced) to effect
  2355.  the desired move.  For simply reformatting  the  screen,  DL  affords
  2356.  control  at  the level of any regions desired.  A command file should
  2357.  be devised for moving cells but only used when really  needed  badly,
  2358.  if  such  actions  are  needed for other reasons.  There will be very
  2359.  little need for them under most circumstances however.   Where  cells
  2360.  must  move  closer  to the origin, an AR command at the origin can be
  2361.  used to provide temporary space in which to move the cells;   at  the
  2362.  end,  they will be moved back further.  The IR command (Inplace Relo-
  2363.  cate) can be used to  avoid  major  moving  around  the  sheet.   The
  2364.  *U HERE  function will return the current max column in accumulator W
  2365.  and the current max row in accumulator Y to facilitate  this.   These
  2366.  maxima  can  be  used to write an efficient command file to copy only
  2367.  the areas in use.  Internal loops in a formula  (with  the  *U  XQTCM
  2368.  function) are the fastest way to implement such a loop.  
  2369.  
  2370.  
  2371.  
  2372. AnalytiCalc Reference Manual                                   Page 47
  2373.  
  2374.  
  2375.  
  2376.                         TEST expression command
  2377.  
  2378.        TEST
  2379.  
  2380.       TE expression    Evaluate expression, save in %
  2381.  
  2382.  
  2383.       The  TEst  command allows command level calculations, for use in
  2384.  controlling loops.  It evaluates the expression (up to 79  characters
  2385.  long)  and  stores in the % accumulator.  Useful for *J type commands
  2386.  to control branching in AnalytiCalc.  Any expression may  be  handled
  2387.  in  a  TE  command,  and  forms of the sort Z=expression are allowed.
  2388.  NOTE however that it is frequently desirable from  command  files  to
  2389.  add a C to the end of the formula since sometimes junk from preceding
  2390.  lines is not zeroed.  The \*C causes it to be treated  as  a  comment
  2391.  and ignored.  
  2392.  
  2393.       The  TEst command will calculate formulas even in restricted re-
  2394.  calculation modes (RM mode, RE mode, or  RI  mode)  since  it  ALWAYS
  2395.  evaluates the expression regardless of mode.  The construct to evalu-
  2396.  ate a cell with a command like 
  2397.  
  2398.       TE V1=__{V1 
  2399.  
  2400.  (which sets a cell value to the computed value of its formula) is ex-
  2401.  plicitly legal and can be used where it is desired to perform irregu-
  2402.  lar partial recomputations while in RM mode.  
  2403.  
  2404.  
  2405.                           VIEWSCREEN Control
  2406.  
  2407.          VIEWSCREEN UPDATE
  2408.  
  2409.       V           Redraw screen with normal formats
  2410.       VF          Redraw screen showing all formulas
  2411.       VM          Don't redraw screen until a V or VF is
  2412.                           given.
  2413.       VC          Turn on color mode (AnalytiCalc-88 only)
  2414.                           "View Color"
  2415.       VB          Turn on black and white mode (AnalytiCalc-88
  2416.                           only) (Default mode; works on both
  2417.                           color and mono based systems.)
  2418.                           "View Black and white"
  2419.       VI          View IBM - use black and white display via
  2420.                           IBM PC BIOS rather than ANSI.SYS driver
  2421.                           for cursor control.
  2422.  
  2423.  
  2424.       The V and VF commands redraw the display screen showing numerics
  2425.  as numerics in the selected format (V) or displaying whatever part of
  2426.  
  2427. AnalytiCalc Reference Manual                                   Page 48
  2428.  
  2429.  
  2430.  
  2431.  the  formulas  fits  on  screen  in  the  column  (VF).  This is used
  2432.  wherever the picture on the screen is  damaged,  e.g.,  by  operating
  2433.  system  broadcasts.   VM  is  used  to  inhibit redraw while numerous
  2434.  changes may be made, to save time.  A V or VF command will re  enable
  2435.  display  updates.   The  VC  and VB commands switch between black and
  2436.  white and color displays  on  AnalytiCalc-88  (MSDOS).   The  program
  2437.  starts  in  black  and white mode (since color may not be readable on
  2438.  some black and white monitors), and will do a beautiful color display
  2439.  if  switched.   The VI mode uses the IBM BIOS video IO interrupt (10)
  2440.  to access the screen, bypassing  ANSI  escape  sequences  altogether.
  2441.  Note  that  negative  numbers  are  highlighted on ANSI screens;  the
  2442.  direct BIOS screen does not do this but is otherwise the same in  ap-
  2443.  pearance  as  the  black and white ANSI screen.  The initial question
  2444.  about screen mode determines whether the  initial  mode  is  VB  mode
  2445.  (Ansi)  or  VI  mode  (IBM)  so  the  display  will  look sensible if
  2446.  AnalytiCalc is started on a machine without ANSI.SYS.  
  2447.  
  2448.  
  2449.                    Writing ASCII images of Displays
  2450.  
  2451.          WRITING SCREEN TO HARDCOPY OR FILES
  2452.  
  2453.          W     Write screen to file
  2454.  
  2455.       The W command lets you write a hard copy of the screen as it ex-
  2456.  ists on display to a file.  AnalytiCalc will prompt you for the  file
  2457.  name;  the device specifier should be included.  
  2458.  
  2459.       Note that if the filename you enter (or the last character after
  2460.  the device or file specifier) is a "/"  character,  AnalytiCalc  will
  2461.  omit the column and row labels in the output file or printout so that
  2462.  you need not edit them out afterwards.  They will always be displayed
  2463.  on the screen however.  
  2464.  
  2465.       To  output  to  the  lineprinter on a PC, the file specifiers to
  2466.  give are either "LPT1:" or "LPT1:/", then.  The output  file  in  any
  2467.  case  has  no  strange  escape  sequences  and may be edited with any
  2468.  normal system editor.  To junk any  output  you  don't  want,  use  a
  2469.  filename of NUL and to go to a generic printer on MSDOS you may use a
  2470.  filename of PRN.  If the character "%" appears in the file specifier,
  2471.  the  title  will  not  be displayed on printout.  This is designed to
  2472.  help those producing  paste-together  printouts  from  several  sheet
  2473.  areas.  
  2474.  
  2475.  
  2476.                              EXIT command
  2477.  
  2478.          EXIT
  2479.  
  2480.    X           Exit to operating system.
  2481.  
  2482. AnalytiCalc Reference Manual                                   Page 49
  2483.  
  2484.  
  2485.  
  2486.  
  2487.  
  2488.       The  X  command  exits from AnalytiCalc to the operating system.
  2489.  In general, this is the ONLY way (short of an abort  command  to  the
  2490.  operating  system)  to get out of AnalytiCalc, and is the ONLY WAY TO
  2491.  LEAVE GRACEFULLY.  You should use the PP or PD command to  save  your
  2492.  sheet  prior to XD if you want to save your sheet;  otherwise it will
  2493.  be lost.  Be at least that cautious;  the program will NOT keep track
  2494.  of whether you've saved the sheet or not.  
  2495.  
  2496.  
  2497.                              ZEROing cells
  2498.          ZERO VARIABLES
  2499.  
  2500.     ZA           Zero whole sheet
  2501.     ZE V1:V2     Zero variables in a row or column
  2502.                  in range from cell V1 to cell V2
  2503.                  (V1,V2 = names of cells)
  2504.  
  2505.  
  2506.       The  ZEro  commands clear out a sheet.  The ZA command will also
  2507.  ask if you mean it and needs a reply of Yes to actually  clobber  the
  2508.  whole sheet and return it to pristine purity.  
  2509.  
  2510.       The ZA command occasionally takes a noticeable time to clear the
  2511.  workfiles out;  do not be alarmed at this.  It  will  ask  afterwards
  2512.  for a new title, new display format default for floating point, etc. 
  2513.  
  2514.       If  you give the ZA command, AnalytiCalc will ask you to confirm
  2515.  that you indeed want to zero the entire sheet.  A  reply  of  Y  will
  2516.  proceed  to  execute  the  command;   any  other reply will abort the
  2517.  clearing operation.  
  2518.  
  2519.  
  2520.  
  2521. AnalytiCalc Reference Manual                                   Page 50
  2522.  
  2523.  
  2524.  
  2525.                         TEXT SEARCH OF FORMULAS
  2526.     SEARCH for formula substring
  2527.  
  2528.      >STRING      Find cell whose formula contains STRING
  2529.      >>STRING     Find cell whose formula starts with
  2530.                      STRING
  2531.  
  2532.  
  2533.       The  >  command  (greater  than sign) causes a search to be made
  2534.  from the current position down and right to the relocate boundary for
  2535.  a  formula  containing  the  string after the >.  The cell found (the
  2536.  first one) will become the current cell.  The origin  is  not  moved,
  2537.  but  the command OA P## will cause the cell found to become the upper
  2538.  left cell on the screen if desired.  This is a handy tool for  locat-
  2539.  ing sections of a large sheet.  The comparison is between the entered
  2540.  string and the formula, but terminates with the shorter.   Therefore,
  2541.  aliasing  occasionally occurs.  Just skip past the offending cell and
  2542.  redo to continue to search.  The >>STRING form anchors the search  at
  2543.  the  start  of  the  string so this will not occur, though very short
  2544.  formulas whose beginnings match the search string  will  match.   The
  2545.  underscore   character  (_)  is  a  wildcard  character  for  formula
  2546.  searches.  
  2547.  
  2548.  
  2549.                 Driving AnalytiCalc from Command Files
  2550.  
  2551.       EXECUTING COMMAND FILES
  2552.  
  2553.     @filespec    Read filespec and execute commands
  2554.                  as though typed in.
  2555.  
  2556.  The @ command lets you treat a file as though it  were  your  console
  2557.  input  (returns on endfile) to let you execute saved sets of commands
  2558.  to set up your sheets.  Note that if you issue the K command (below),
  2559.  those inputs come from a separate file on logical unit 1.  
  2560.  
  2561.                    Recording Commands Interactively
  2562.  
  2563.          JOURNALING
  2564.  
  2565.    +J filename   Opens filename as a journal file,
  2566.                  recording commands to that file.
  2567.                  (Note: auxiliary inputs are not so
  2568.                  recorded, where asked for as separate
  2569.                  questions.)
  2570.    +N            Closes any open journal file
  2571.  
  2572.  
  2573.       The  journaling commands allow typed commands to be saved into a
  2574.  file later usable as an indirect  command  input  to  AnalytiCalc  to
  2575.  
  2576. AnalytiCalc Reference Manual                                   Page 51
  2577.  
  2578.  
  2579.  
  2580.  allow recreation of screen formats, data, formulas, etc.  Extra ques-
  2581.  tions (e.g.  those used for filename and areas to save or restore  in
  2582.  P  or  G  class commands) are NOT saved by the journal.  They will be
  2583.  read by @ commands however and may be edited into a journal file with
  2584.  any  editor.   If  this  is desired inside a AnalytiCalc session, the
  2585.  Spawn command (below) is recommended after the +N command is used  to
  2586.  close  the  file.   The  VM  and RM commands are recommended inside @
  2587.  files (with R and V commands at the ends) to suspend display updating
  2588.  and  recalculation  until  all commands in the journal file are done.
  2589.  The Journal command is the way to get AnalytiCalc  to  remember  your
  2590.  keystrokes  when  making  up  any  command  so that you can tell what
  2591.  you're doing.  Later if you don't need to watch  the  screen  update,
  2592.  use  the  VM  command (View Manual) to turn display update off during
  2593.  the command files' operation, and the V (View)  command  to  turn  it
  2594.  back  on at the end.  The major uses of journaling are to save screen
  2595.  formats as they are set up and to allow capture of keystrokes for use
  2596.  in command macros.  
  2597.  
  2598.          Executing Other Programs or Commands from AnalytiCalc
  2599.         $ command-line     EXEC command line to the OS
  2600.                              (minus the $ sign). May
  2601.                              need extra CR to free
  2602.                              console.
  2603.         } command-line     EXEC command line (minus the })
  2604.                              and await a return on console
  2605.                              before return to sheet.
  2606.  
  2607.       The  $ command permits AnalytiCalc to spawn commands to the host
  2608.  OS.  The command is whatever follows the $ and results in  that  com-
  2609.  mand being EXECed to DOS.  This permits use of other system utilities
  2610.  during a session with AnalytiCalc.  The variant using the } character
  2611.  rather  than  the  $ character will print the message ENTER RETURN TO
  2612.  REDRAW SPREADSHEET> at the bottom of the screen and will not  repaint
  2613.  the  screen until the return key is pressed.  This allows you to exa-
  2614.  mine the screen as long as needed before erasing  and  redrawing  the
  2615.  sheet.   NOTE  that in a minimum 256K system you will NOT HAVE ENOUGH
  2616.  MEMORY to execute other commands.   The  size  program  you  can  run
  2617.  depends  on  the  amount  of  memory you have left.  The commands are
  2618.  passed to COMMAND.COM and executed if room enough exists  to  do  so.
  2619.  The graphics tasks are designed to be invokable this way.  
  2620.  
  2621.                       Interactive Calculator Mode
  2622.  
  2623.       DROPPING INTO INTERACTIVE CALCULATOR
  2624.  
  2625.        K       Drop into interactive Calculator
  2626.  
  2627.  
  2628.       The  K command gets you into Calc, described below, and lets you
  2629.  do computations.  When you give the interactive Calc program  the  *E
  2630.  
  2631. AnalytiCalc Reference Manual                                   Page 52
  2632.  
  2633.  
  2634.  
  2635.  command  to  exit, you return to the spreadsheet.  This may be useful
  2636.  where you want to do auxiliary computations not in the  spread  sheet
  2637.  or  try  out formulas that you may want to debug interactively before
  2638.  entering them onto the sheet.  This calculator  knows  decimal,  hex,
  2639.  and  octal  radices  and  can be used to debug indirect command files
  2640.  written for use within spreadsheet cells;  the *V 3  command  can  be
  2641.  given  and  then  the  *@file  can be given in Calc mode, providing a
  2642.  trace playback of the actions of a command file to see what it is do-
  2643.  ing.  
  2644.  
  2645.  
  2646.                  Conditional Restart of Command Files
  2647.  
  2648.          LOOPING COMMAND FILES
  2649.  
  2650.       <        Rewind the current AnalytiCalc input file
  2651.  
  2652.  
  2653.       This  command  will  allow a command file to restart itself from
  2654.  the beginning.  It does so only if the % variable is  positive  (per-
  2655.  mitting  some control over it).  A command file may use the TEst com-
  2656.  mand to set the % variable prior to this command.  
  2657.  
  2658.       In  AnalytiCalc-86  V18-06 and later, an < found in a cell equa-
  2659.  tion causes the cell equation to be re-evaluated from  the  start  of
  2660.  the formula, PROVIDED that the "<" is seen at the start of one of the
  2661.  cell's equations, AND that the % accumulator is greater than  0.0  at
  2662.  that  time.   This  is provided to allow use in conjunction with *WF,
  2663.  *P, and *U XQTCM so that multi-equation formulas can loop, doing jobs
  2664.  like  selecting rows from regions, entering sequences of numbers, and
  2665.  the like.  This provides a compact and fast  looping  structure  that
  2666.  does  not  depend on rewinding files externally.  The *U XQTCM TE {V1
  2667.  construct is not supported however.  The looping  is  limited  to  at
  2668.  most 100 passes to prevent infinite loops.  
  2669.  
  2670.  
  2671.  
  2672. AnalytiCalc Reference Manual                                   Page 53
  2673.  
  2674.  
  2675.  
  2676.                            COMMENT commands
  2677.  
  2678.          COMMENTS
  2679.  
  2680.          * any text
  2681.  
  2682.       Any line beginning with * is treated by AnalytiCalc as a comment
  2683.  (except when in the *F mode when it is sought).  This allows  you  to
  2684.  comment your indirect AnalytiCalc command files.  
  2685.  
  2686.  
  2687.              Prompting for Data to be EDited into formulas
  2688.  
  2689.          READING ARGUMENTS OFF CONSOLE
  2690.  
  2691.          - Prompt
  2692.  
  2693.       The  "-"  command  will  print the prompt text on the screen and
  2694.  await entry of a line of text.  This text is stored as up to 4  argu-
  2695.  ments for possible later use in EDit commands.  Spaces separate input
  2696.  arguments, and no argument may be longer than  51  characters.   This
  2697.  facility  is  intended  for use with indirect command files (@ files)
  2698.  which may want to be able to prompt for parts of  formulas  and  then
  2699.  edit  them  into the command formulas for use, or to prompt for parts
  2700.  of later-used Calc commands.  Note that Calc never sees any  formulas
  2701.  that  are given the A format, so they can be prepared in this way, to
  2702.  be used when they are given a numeric format.  
  2703.       A suitable - command might be 
  2704.  
  2705.  -Enter net pay> 
  2706.       which would produce the printout (in row 23 of the screen) 
  2707.  Enter net pay> 
  2708.       and  to which one might reply with a number to be entered onto a
  2709.  "template" worksheet.  
  2710.  
  2711.  
  2712.                            Application Notes
  2713.  
  2714.  
  2715.       In  entering  numbers, use a decimal (.) to get them to go in as
  2716.  floating point.  If numbers are entered with no  decimals,  they  are
  2717.  considered  integers.  The system will convert the values to floating
  2718.  point for storage, but incorrect results have occurred where  formula
  2719.  ranges have been mixed since multi-argument functions assume the con-
  2720.  versions are all alike in their ranges, and  binary  formats  of  in-
  2721.  tegers and floating point numbers differ greatly.  
  2722.  
  2723.       Note that the default format for numeric output is F9.2 and that
  2724.  it may be changed if desired.  If you set up the format  of  a  cell,
  2725.  that  marks  the  cell  valid  and the format is not altered by input
  2726.  
  2727. AnalytiCalc Reference Manual                                   Page 54
  2728.  
  2729.  
  2730.  
  2731.  defaults, nor the numeric/text interpretation of the cell.  To put in
  2732.  a  lot  of  labels, then, set up format A using DF and then enter the
  2733.  labels.  
  2734.  
  2735.       If  the sheet's calculations contain forward references (down or
  2736.  right), you may need to give the R (Recalculate) command a few  times
  2737.  to  get  proper values.  If the values on the sheet do not stabilize,
  2738.  you probably have a circular reference in your  formulas  and  should
  2739.  examine  the cells that do not stabilize for the circularity.  Calcu-
  2740.  lation is done across first (along rows first).  This allows any file
  2741.  references to be as nearly sequential as possible.  
  2742.  
  2743.       If  you enter numbers with exponentials, use +/- in front of the
  2744.  E so that AnalytiCalc can tell that the "E4" type strings in  numbers
  2745.  like "1.3E4" are really exponents, not cell names.  That is, 
  2746.       Don't enter 
  2747.          1.35E4 
  2748.       Enter 
  2749.          1.35E+4 
  2750.  to  avoid  confusion  when  cells are relocated.  Filenames that look
  2751.  like cell names should be avoided too.  That is, a  sheet  that  con-
  2752.  tains a formula like 
  2753.  @D5.FRM 
  2754.  might, upon getting moved from D5 to F3, be changed to 
  2755.  @F3.FRM 
  2756.  and IF this is not what is desired, it could cause confusion.  
  2757.  
  2758.  Note  that column widths on the display are properties of the DISPLAY
  2759.  columns, not the PHYSICAL columns.  This  arises  because  a  display
  2760.  column  may  cover  potentially  20 different physical columns on the
  2761.  sheet due to mapping.  That is, column 3 may have cells from column C
  2762.  of the physical sheet, but can be set to have cells also from columns
  2763.  R, AZ, Q, and W (for example), with  different  display  formats  for
  2764.  each.   Rather  than  choosing  some width a function of the physical
  2765.  columns which could cause confusion, the width is  up  to  you.   The
  2766.  columns  are  labelled  with the physical cell column of the adjacent
  2767.  cell in the top row and also with the display column number  to  make
  2768.  it  easier  to enter DL commands, which use display coordinates (pure
  2769.  numeric, column:row) rather than physical coordinates  (alphanumeric,
  2770.  e.g.  AK15).  
  2771.  
  2772.                     Interactive Calculator Section
  2773.            THE CALC MODE OPTION (K) and Functions Available:
  2774.  
  2775.       This  describes the CALC option (K) of AnalytiCalc which is also
  2776.  the mathematical engine used for  expression  evaluation  except  for
  2777.  multi-argument functions and IF statements.  
  2778.  
  2779.       NOTE:  
  2780.  
  2781.  
  2782. AnalytiCalc Reference Manual                                   Page 55
  2783.  
  2784.  
  2785.  
  2786.       You will need to use the command 
  2787.  
  2788.       *V 3 
  2789.  
  2790.  to  get  any numbers displayed initially;  AnalytiCalc initially sets
  2791.  the display View flag to zero for speed reasons.  
  2792.  
  2793.                                OVERVIEW
  2794.  
  2795.       CALC  mode  is  a calculator designed to evaluate arithmetic ex-
  2796.  pressions.  In its basic form, expression evaluation  is  similar  to
  2797.  that  used  by  ANSI FORTRAN with calculations performed on INTEGER*4
  2798.  and REAL*8 constants.  Variables may also be invoked.   Standard  al-
  2799.  gebraic  operator  precedence is used, and accumulators (A through Z,
  2800.  %, and all spreadsheet cells) may be assigned values by  Calc  state-
  2801.  ments of the form:  
  2802.  
  2803.       Accumulator=expression 
  2804.  
  2805.       Additional  features  include  octal  and hexadecimal arithmetic
  2806.  capabilities.  Commonly used commands and expressions can  be  placed
  2807.  in a file and executed when convenient.  
  2808.  
  2809.                         How to Enter CALC mode
  2810.  
  2811.       To enter Calc, use the K command of AnalytiCalc.  Calc mode will
  2812.  prompt as follows:  
  2813.  
  2814.         CALC> 
  2815.  
  2816.  Before starting in this mode, type the command 
  2817.  
  2818.       *V 3 
  2819.  
  2820.       to get the interactive portion to display results.  Now try typ-
  2821.  ing 
  2822.  
  2823.         123+456 
  2824.  
  2825.  followed by a carriage return.  CALC will evaluate the expression and
  2826.  output the answer 
  2827.         579 
  2828.  
  2829.  It then prompts for further input.  Try other expressions such as 
  2830.      12.0 - 99.               (answer=-87.00000000000000)
  2831.      -(-32767+(6-2)**8-(512/(409-401)))   (answer=-32705)
  2832.      3*5/7                                     (answer=2)
  2833.      3*(5/7)                                   (answer=0)
  2834.  
  2835.  
  2836. AnalytiCalc Reference Manual                                   Page 56
  2837.  
  2838.  
  2839.  
  2840.       Mixed mode is legal, for example 
  2841.  
  2842.         1977/50.  is evaluated as 39.54000000000000 
  2843.  
  2844.  
  2845.  Reals may be expressed using D or E format.  For example 
  2846.  
  2847.         1.2E10*2.D0**3-1.D-8 is evaluated as 
  2848.  
  2849.         0.95999999999999992D+11 
  2850.  
  2851.                              Accumulators
  2852.  
  2853.       Variables  may  also  be  used  to  retain values for later use.
  2854.  Variables may be the letters A through Z, or any AnalytiCalc physical
  2855.  sheet cell name.  All accumulators default to REAL type.  To set I to
  2856.  a value use the usual FORTRAN syntax, for example:  
  2857.  
  2858.         I=2**10-1 
  2859.  
  2860.  Try  typing  the  single  character  'I'.  CALC will respond with its
  2861.  value.  We can now use I in various expressions such as 
  2862.  
  2863.         J=I-I/3*3 
  2864.  
  2865.       %  is  a special variable that retains the value of the last ex-
  2866.  pression evaluated.  For example, to successively add up the  numbers
  2867.  1, 2, 3, 4, 5, and 6 we could enter 
  2868.  
  2869.        1
  2870.        %+2
  2871.        %+3
  2872.        %+4
  2873.        %+5
  2874.        %+6
  2875.  
  2876.       Note  that  you can examine the value of the variables by typing
  2877.  the appropriate single character followed by a carriage return.  Such
  2878.  an examination does not change the value of %.  
  2879.  
  2880.                     Getting Back to the Spreadsheet
  2881.  
  2882.       To exit from CALC, type 
  2883.  
  2884.         *E (or *EXIT) 
  2885.      or *S (or *STOP) 
  2886.  
  2887.  This will return you to AnalytiCalc.  (To exit AnalytiCalc, use the X
  2888.  command.) 
  2889.  
  2890.  
  2891. AnalytiCalc Reference Manual                                   Page 57
  2892.  
  2893.  
  2894.  
  2895.             Mathematical Functions for Calc and AnalytiCalc
  2896.                           -SPECIAL FUNCTIONS-
  2897.  
  2898.       CALC recognizes a variety of special functions.  For example, to
  2899.  calculate the square root of 2, we can type 
  2900.  
  2901.         SQRT(2.) 
  2902.  
  2903.  CALC responds with the value 1.41421356237310 
  2904.  
  2905.       Each  function may have an expression for its argument.  For ex-
  2906.  ample, 
  2907.  
  2908.       A=2.0*SQRT(ALOG(9.)+3.) 
  2909.  
  2910.  sets A to 4.55948443459838 
  2911.  
  2912.       The following special functions are available:  
  2913.  
  2914.   FUNCT NAME   ARG TYPE    FUNCT VALUE   DESCRIPTION
  2915.   -------------------------------------------------------
  2916.   ABS          REAL        REAL         absolute value
  2917.   DABS         REAL        REAL         absolute value
  2918.   IABS         INTEGER     INTEGER      absolute value
  2919.   IFIX         REAL        INTEGER      REAL to INT conv.
  2920.   AINT         REAL        REAL         REAL truncation
  2921.   INT          REAL        INTEGER      REAL to INT conv.
  2922.   IDINT        REAL        INTEGER      REAL to INT conv.
  2923.   EXP          REAL        REAL         e**X
  2924.   DEXP         REAL        REAL         e**X
  2925.   ALOG         REAL        REAL         natural logarithm
  2926.   DLOG         REAL        REAL         natural logarithm
  2927.   ALOG10       REAL        REAL         logarithm base 10
  2928.   DLOG10       REAL        REAL         logarithm base 10
  2929.   SQRT         REAL        REAL         square root
  2930.   DSQRT        REAL        REAL         square root
  2931.   SIN          REAL        REAL         trigonometric sine
  2932.   DSIN         REAL        REAL         trigonometric sine
  2933.   COS          REAL        REAL         trig. cosine
  2934.   DCOS         REAL        REAL         trig. cosine
  2935.   TANH         REAL        REAL         hyperbolic tangent
  2936.   DTANH        REAL        REAL         hyperbolic tangent
  2937.   ATAN         REAL        REAL         arc tangent
  2938.   DATAN        REAL        REAL         arc tangent
  2939.  
  2940.  
  2941.       Note  that  the  multi  argument  functions  (e.g.   SUM[range],
  2942.  AVG[range], etc., are all also available in CALC mode with  the  same
  2943.  restrictions  mentioned above.  The IF [expression]yes-expr|else-expr
  2944.  
  2945. AnalytiCalc Reference Manual                                   Page 58
  2946.  
  2947.  
  2948.  
  2949.  command is however NOT available in CALC mode;  use the *J expression
  2950.  instead (see below).  
  2951.  
  2952.                   -WORKING IN OCTAL AND HEXADECIMAL-
  2953.  
  2954.       You  may  change the base used to specify constants by using the
  2955.  *B command.  Legal forms are 
  2956.  
  2957.       command              action
  2958.       -------              ------
  2959.         *B             displays current default base
  2960.         *B 8           changes default base to octal
  2961.         *B 10          changes default base to 10
  2962.         *B 16          changes default base to 16
  2963.  
  2964.       Suppose we have changed the default base to octal.  Then adding 
  2965.  
  2966.         7 + 1 
  2967.  
  2968.  we obtain the result 
  2969.  
  2970.         00000000010 (BASE 8) 
  2971.  
  2972.  If the default base is hexadecimal, we can enter 
  2973.  
  2974.         9 + 1 
  2975.  
  2976.  which is evaluated as 
  2977.  
  2978.         0000000A (BASE 16) 
  2979.  
  2980.  Suppose we have assigned 
  2981.         A=1 
  2982.  then 
  2983.         1+A 
  2984.  gives 
  2985.         2.000000000000000 
  2986.  
  2987.  even  when the default base is 16.  If we wish to add the hexadecimal
  2988.  digit 'A' to 1, enter 
  2989.  
  2990.         1+0A 
  2991.  
  2992.  We now obtain the desired 
  2993.  
  2994.         0000000B (BASE 16) 
  2995.  
  2996.       This  leading  0  is  only  necessary when the first hexadecimal
  2997.  digit is greater than 9.  
  2998.  
  2999.  
  3000. AnalytiCalc Reference Manual                                   Page 59
  3001.  
  3002.  
  3003.  
  3004.       If  constants are entered with digits that are not legal for the
  3005.  base being  used,  the  entire  number  is  converted  using  a  more
  3006.  appropriate  base.   For  example, if we have set the default base to
  3007.  octal and type 
  3008.         1+9 
  3009.  
  3010.       the  9 is not an octal number so it is converted to base 10.  If
  3011.  a base 16 number is involved, the result will be in base 16.  
  3012.  
  3013.       You  may  temporarily  change the base for a single integer con-
  3014.  stant by preceeding it with 
  3015.  
  3016.         ^8 for octal 
  3017.         ^10 for base 10 
  3018.         ^16 for base 16 
  3019.  
  3020.  For example, if the default base is 10, 
  3021.         100+^840 
  3022.  gives 
  3023.         132 
  3024.  
  3025.  a base 10 integer.  
  3026.  
  3027.         I=100+^1610 
  3028.  
  3029.  gives 
  3030.         116 
  3031.  
  3032.  also a base 10 integer.  
  3033.  
  3034.       Note  that  the '^' can only be used to specify the base of con-
  3035.  stants and that expressions such as ^16I are illegal.  
  3036.  
  3037.       To  declare  variables to be integers of a specific base, we can
  3038.  use the commands 
  3039.     *INTEGER        (base 10)
  3040.     *OCTAL          (base 8)
  3041.     *HEX            (base 16)
  3042.  for example, 
  3043.     *INTEGER A     declares variable A to be a
  3044.                    base 10 integer.
  3045.     *HEX B,Z,F     declares variables B, Z, and
  3046.                    F to be base 16 integers.
  3047.     *DECIMAL       lists all the variables that
  3048.                    have been declared to be
  3049.                    of type DECIMAL.
  3050.  
  3051.  
  3052.       To  summarize,  there  are  three  distinct  ways of making base
  3053.  declarations when using CALC.  The first is to use the *B command  to
  3054.  
  3055. AnalytiCalc Reference Manual                                   Page 60
  3056.  
  3057.  
  3058.  
  3059.  designate the base default value.  This is used to determine the base
  3060.  for constants when they occur in expressions.  It does not in any way
  3061.  influence the type of any variables found in an expression.  The only
  3062.  way to change the type of a variable is with a specific CALC  command
  3063.  such as 
  3064.         *INTEGER A,B 
  3065.  
  3066.       Note  that  the  *INTEGER  command  can be used to set types for
  3067.  AnalytiCalc cells.  However, exercise care in doing so that your dis-
  3068.  play formats match the new type.  
  3069.  Suppose for example that the default base is 10 and we enter 
  3070.         *OCTAL A 
  3071.         A=100 
  3072.  
  3073.  then CALC responds with 
  3074.         00000000144 (BASE 8) 
  3075.  
  3076.       Finally,  the  last  way to change a base is to use the explicit
  3077.  base specifiers for a constant, for example 
  3078.  
  3079.       ^10 123 
  3080.       ^8 777 
  3081.       ^16 AB 
  3082.  
  3083.                  Commands and Other Functions for Calc
  3084.                             and AnalytiCalc
  3085.  
  3086.       All  commands  to  CALC (as distinguished from expressions to be
  3087.  evaluated) begin with an asterisk.  To obtain a list of all  possible
  3088.  commands,  type  a question mark followed by a carriage return.  Most
  3089.  of the commands have already been described.  The  following  section
  3090.  gives  an  explanation of the remaining commands.  Many of these have
  3091.  the role of functions too, and may change the value of % or other ac-
  3092.  cumulators.  
  3093.  
  3094. AnalytiCalc Reference Manual                                   Page 61
  3095.  
  3096.  
  3097.  
  3098.      COMMAND            DESCRIPTION
  3099.      -------            -----------
  3100.   *@filename      Where  filename  is  the name of a file of CALC com-
  3101.                mands.  CALC reads the file and executes the  commands.
  3102.                Up  to 5 nested calls can be made.  Recursive calls are
  3103.                not allowed.  CALC prompts  with  CALC<n>  before  each
  3104.                command line is executed, where n is the calling level.
  3105.                You may optionally follow the file name  with  a  blank
  3106.                followed by a single variable name (a single alphabetic
  3107.                character or %).  CALC will then execute the file until
  3108.                the  value  of  that variable is zero or negative.  The
  3109.                test of this variable is made before the file  is  exe-
  3110.                cuted  and  not during execution of commands within the
  3111.                file.  If the variable's value is not positive when the
  3112.                command  is initially encountered, the file will not be
  3113.                opened for execution.   This  facility  allows  any  or
  3114.                every  cell  to  be  driven  by  command files while in
  3115.                spreadsheet mode.  
  3116.   *ASCII     Declares a list of variables to be of type ASCII.  Useful
  3117.                when decoding ASCII characters.  For example, if we set
  3118.                A  to be of type ASCII, then typing A=77 results in the
  3119.                character 'M' being output.  The inverse  operation  is
  3120.                the  single  quote.   It  allows us to specify a single
  3121.                ASCII constant.  For example, if we type 
  3122.                'M 
  3123.                then  the  character 'M' is echoed and indicates that %
  3124.                holds that character and has data type ASCII.   Suppose
  3125.                that the variable I has data type INTEGER.  Then we can
  3126.                output the base 10 code for the ASCII character 'M'  by
  3127.                entering 
  3128.                I='M 
  3129.                which  results in 77 being output.  Notice that you may
  3130.                not be able to enter certain  control  characters  that
  3131.                are  intercepted  by your operating system.  Characters
  3132.                whose value is less than 32.  are  output  by  printing
  3133.                the  character  '^'  followed  by  the equivalent ASCII
  3134.                character of that number plus 32.  For example, 
  3135.                A=10 
  3136.                results in 
  3137.                ^* 
  3138.                being  output  since  42  is  the  ASCII  code  for the
  3139.                character '*'.  See Appendix  A  for  a  table  of  the
  3140.                characters   output   by   CALC   to   represent   such
  3141.                non-printable characters.  
  3142.   *C      COMMENT  line.   The  characters  that follow are ignored by
  3143.                CALC.  This is useful when documenting files containing
  3144.                CALC commands.  
  3145.   *N      NOVIEW.   Prevents CALC from outputting the value of the ex-
  3146.                pressions evaluated.  This is  especially  useful  when
  3147.                executing   files   containing   CALC   commands   that
  3148.  
  3149. AnalytiCalc Reference Manual                                   Page 62
  3150.  
  3151.  
  3152.  
  3153.                initialize variables to special values.  Equivalent  to
  3154.                *V 1 
  3155.   *V     VIEW.  Controls CALC's printing options:  
  3156.  
  3157.                  command    output class
  3158.                  --------   --------------
  3159.                   *V 0       error messages
  3160.                
  3161.                   *V 1       error messages
  3162.                              command lines read
  3163.                                from files
  3164.                
  3165.                   *V 2       error messages
  3166.                              value of expressions
  3167.                                evaluated
  3168.                
  3169.                   *V 3       error messages
  3170.                              command lines read
  3171.                                from a file
  3172.                              value of expressions
  3173.                                evaluated
  3174.                   *V         same as *V 3
  3175.  
  3176.                The  default  setting is *V 0.  Notice that other legal
  3177.                forms are *VIEW 1 and *V2.  You may want to  include  a
  3178.                command  *V  0 somewhere before using any command files
  3179.                to avoid diagnostic printouts if you use indirect  cell
  3180.                files much.  
  3181.   *R      READ.   Allows  a  single line to be read from the terminal.
  3182.                Useful in files of CALC commands  to  allow  additional
  3183.                commands to be entered (like *S to exit from that file)
  3184.                or simply as a way to halt terminal  output  until  the
  3185.                carriage return key is pressed.  
  3186.   *REAL     declares specified variables to be REAL*8.  When the value
  3187.                of such variables are output,  FORTRAN's  D  format  is
  3188.                used.  
  3189.   *DECIMAL      Declares  specified  variables to be REAL*8.  When the
  3190.                value of such variables are output, FORTRAN's F  format
  3191.                is  used.   Variables  A-H  and  O-Z  default  to  type
  3192.                DECIMAL.  
  3193.   *S     STOP.  Same as *E 
  3194.   *E      EXIT.   Terminates  CALC  session unless it is used within a
  3195.                file of CALC commands.  In this case, CALC  closes  the
  3196.                file and continues with the next command.  
  3197.   *Z      ZERO.   Zeroes  all  variables except %.  Data types are not
  3198.                changed.  
  3199.   *G        *G  V1,V2  (where V1 and V2 are cell or accumulator names)
  3200.                will evaluate V1 and V2 as the column and row  numbers,
  3201.                on  the  physical  sheet, of the desired cell.  The ad-
  3202.                dressed cell's value  is  retrieved  and  used  as  the
  3203.  
  3204. AnalytiCalc Reference Manual                                   Page 63
  3205.  
  3206.  
  3207.  
  3208.                resulting number.  This is used for lookup tables.  
  3209.   *W        Takes  the  value at the current cell and writes it out to
  3210.                the formula as a numeric (floating) value.  The current
  3211.                cell  may have been modified temporarily by the *P com-
  3212.                mand.  This will overwrite the formula  at  that  cell.
  3213.                The  *WF  command  will work the same as *W except that
  3214.                the format used for rewriting the number  will  be  the
  3215.                current  cell's  display  format instead of a pre-fixed
  3216.                D32.25 format.  Some extra  spaces  may  be  introduced
  3217.                which  may  be  removed by the command "ED / //".  This
  3218.                allows  freezing  values  to  whatever   precision   is
  3219.                desired.  
  3220.   *P        The  *P  command  resets  the current cell coordinate from
  3221.                within a cell (until the next cell is evaluated  only).
  3222.                It has several forms:  
  3223.              *P - By itself, *P causes Calc to prompt for the new phy-
  3224.                sical column and row number.  
  3225.              *P V1 - This moves the current location to the named cell
  3226.                where V1 is the cell name (e.g.  A5, H2) 
  3227.              *P@  V1,V2  -  This uses V1 and V2 (cell names) as column
  3228.                and row numbers and changes the current  physical  cell
  3229.                position  to  that  defined by the contents of cells V1
  3230.                and V2.  This gives complete addressing  of  the  sheet
  3231.                from within any cell.  
  3232.   *F         *F Label - If the value in % is positive and nonzero this
  3233.                command rewinds the input file for  the  AnalytiCalc  @
  3234.                command  (not  the  Calc  @  command)  and seeks a line
  3235.                beginning with the characters *CLabel (where "label" is
  3236.                what  you  put after the *F command).  This allows Calc
  3237.                commands inside a cell to direct outside command entry. 
  3238.   *J         *J  Label  -  This  command behaves as the *F command but
  3239.                operates on the file used by the Calc @ command  rather
  3240.                than  the  AnalytiCalc  one.   Thus, conditions in Calc
  3241.                program files may be implemented.  
  3242.  
  3243.                Data File Access 
  3244.  
  3245.   *QF 
  3246.   *QW         The  *QF  (Float)  or  *QW  (write) commands are used to
  3247.                examine sequential files  created  outside  AnalytiCalc
  3248.                and return values or formulas.  Their syntax is 
  3249.            *QF filename ?key1?  ?key2?  <lm> 
  3250.         or *QW filename ?key1?  ?key2?  <lm> 
  3251.                where ?key2?  is optional 
  3252.                l  and  m are delimiter characters for start and end of
  3253.                the parts of the selected records to extract  (defaults
  3254.                to  first part of the record) filename is just the file
  3255.                specifier in the host OS.  operation is that  the  file
  3256.                is  searched  from the beginning for records containing
  3257.                key1 (and key2 if specified) and then the part  of  the
  3258.  
  3259. AnalytiCalc Reference Manual                                   Page 64
  3260.  
  3261.  
  3262.  
  3263.                record  between  character l and character m (delimiter
  3264.                characters, which may be the same as for example 2 com-
  3265.                mas) is extracted.  That part of the record is then ei-
  3266.                ther Floated by converting to a floating  point  number
  3267.                using  a  wide Floating Point format specifier (in *QF)
  3268.                or read in and made the current cell's formula  between
  3269.                those delimiters (in the case of *QW).  Records may not
  3270.                be over 128 characters long.   This  command  would  be
  3271.                used to extract data from a database or word processing
  3272.                files.  
  3273.  
  3274.                     The  first key will begin at the start of the line
  3275.                for each file if it's first character is the `  (accent
  3276.                grave)  character.  Then the key searched for is sought
  3277.                always at the start of the line, minus the ` character. 
  3278.  
  3279.                     The delimiters may contain 3 characters to specify
  3280.                positional fields.  In this case, the  first  delimiter
  3281.                character  is  `  (again)  and the second 2 are encoded
  3282.                start location and length fields.  They  are  just  the
  3283.                binary  values  of these + 32 (starting from 1) to turn
  3284.                them to printable ASCII.  
  3285.  
  3286.                     Variant  forms are *QFK, *QWK (which keep the file
  3287.                open after opening it so that subsequent *QFN  or  *QWN
  3288.                or *QFC or *QWC commands can read sequentially down the
  3289.                file), or the mentioned *QFN and *QWN  commands,  which
  3290.                read the file from the Next record (leaving it open for
  3291.                more Next searches) and the *QFC or *QWC variants which
  3292.                perform the *QFN type action but close the file on com-
  3293.                pletion.  The file spec must be present in *QFN,  *QWN,
  3294.                *QFC,  and *QWC commands, but is ignored there.  If the
  3295.                search fails, the % accumulator is returned as -999999.
  3296.                and  on  *QW type operations where there is no failure,
  3297.                the % accumulator returns a value of  1.0  to  indicate
  3298.                success.  In the *QF commands, the value returned is in
  3299.                the file searched.  These return values  occur  regard-
  3300.                less  of  the variant.  Note that the same logical unit
  3301.                (4) is used for all *Q  class  operations,  so  a  sub-
  3302.                sequent  *QF  or *QW will close the unit after a string
  3303.                of *QN searches of  indeterminate  length.   A  request
  3304.                that searches the null device is a simple way to ensure
  3305.                the unit is closed.  It is possible to  leave  it  open
  3306.                and  interfere  with some other operations, so the user
  3307.                is cautioned to pay attention to this aspect of program
  3308.                operation when designing a sheet that uses it.  
  3309.   *U  funct args      The *U command is a means to allow easy user ad-
  3310.                dition to  the  AnalytiCalc  function  repertoire.   It
  3311.                passes  the command line to the USRFCT subroutine which
  3312.                is set up to recognize up to  5-letter  function  names
  3313.  
  3314. AnalytiCalc Reference Manual                                   Page 65
  3315.  
  3316.  
  3317.  
  3318.                (edit it to add what you need) and to process the func-
  3319.                tions called.  The parsing is up to you.  Note that the
  3320.                VARSCN  routine may be called to convert variable names
  3321.                into coordinates in the XVBLS array.  
  3322.  
  3323.                     Functions supplied include:  
  3324.           DATE  functions  operating  on  dates:  IDATE, YRMOD, JDATE,
  3325.                JTOCH, and DATE which all  return  or  convert  between
  3326.                Julian   dates   (day   since   a   fixed   date)   and
  3327.                year/month/day binary, and ASCII dates.  
  3328.           MATRIX  functions  which  handle matrix math:  MTXEQ, MOVEV,
  3329.                MDET, MPROD, MADDV, MSUBV,  MMPYT,  and  MMPYC.   These
  3330.                handle all variants of normal matrix algebra.  MMPYT is
  3331.                particularly handy for producing the dot product  of  2
  3332.                rows  or columns (sum of products of corresponding ele-
  3333.                ments).  Note that matrix math works only in the  prime
  3334.                area  however.  That is, matrices must reside above and
  3335.                to the left of cell BI301 (so the legal range  for  ma-
  3336.                trices is A1 through BH300).  
  3337.           EQUATION  SOLUTION via the VARY function, which allows up to
  3338.                8 accumulators to vary to iteratively search for  solu-
  3339.                tions to equations anywhere on the sheet.  
  3340.           UTILITY  functions,  including STRVL, which converts formula
  3341.                text to numeric values, XQTCM which  executes  commands
  3342.                from  inside  formulas,  and HERE which returns current
  3343.                location and some extra sheet status information.  
  3344.  
  3345.  
  3346.                DETAILS:  
  3347.  
  3348.                     A version of USRFCT is supplied which can call the
  3349.                system to return the system month, day, and year in ac-
  3350.                cumulators  T,  U,  and  V respectively.  The % returns
  3351.                with a value of yymmdd to permit  easier  sorting  too.
  3352.                However, any functions desired may be added in this way
  3353.                and results extracted in whatever  way  is  convenient.
  3354.                The  yymmdd  value  returned  is a Julian date based on
  3355.                1/1/1980, in the % accumulator.  This  is  the  IDATE()
  3356.                function.  
  3357.  
  3358.                     There  are 4 other date functions supported in the
  3359.                most capable  AnalytiCalcs.   These  permit  conversion
  3360.                between  ASCII  dates  displayed as YY/MM/DD and Julian
  3361.                dates, or back.  
  3362.  
  3363.                     The call 
  3364.  
  3365.                *U YRMOD VY,VM,VD 
  3366.  
  3367.                returns  the  Julian date (in %) computed from the Year
  3368.  
  3369. AnalytiCalc Reference Manual                                   Page 66
  3370.  
  3371.  
  3372.  
  3373.                (in VY), the month (in VM) and the day (in  VD),  where
  3374.                VY,  VM,  and  VD  are  sheet  cells.  These may be the
  3375.                result of date arithmetic.  
  3376.  
  3377.                     The call 
  3378.  
  3379.                *U JDATE Var 
  3380.  
  3381.                assumes  the  formula in cell Var (any spreadsheet cell
  3382.                name) contains a date string in  the  format  YY/MM/DD.
  3383.                It reads this formula and converts the date to a Julian
  3384.                date, returning it in the % accumulator.  
  3385.  
  3386.                     The call 
  3387.  
  3388.                *U JTOCH Jul,Var 
  3389.  
  3390.                assumes  that  variable Jul (any spreadsheet cell) con-
  3391.                tains a Julian date and changes it into an ASCII string
  3392.                in  the  cell  whose  name is in the Var position here.
  3393.                This wipes out  any  previous  formula  in  that  cell,
  3394.                though  it does not alter display format or type infor-
  3395.                mation.  The T, U, and V accumulators return  with  the
  3396.                month, day, and year on return.  
  3397.  
  3398.                     The call 
  3399.  
  3400.                *U DATE VY,VM,VD,Var 
  3401.  
  3402.                uses  VY,  VM,  and VD as year, month and day, and com-
  3403.                putes a Julian date from them.   It  then  composes  an
  3404.                ASCII  string of form YY/MM/DD for that date and stores
  3405.                in the formula for Var.  
  3406.  
  3407.                     The  use  of Julian dates is made because the dif-
  3408.                ference of two Julian dates is precisely the number  of
  3409.                days  between  the  two  dates.   These  functions  are
  3410.                designed to make date labels easier to do.  
  3411.  
  3412.                     There  are  actually  4  supplied USRFCT routines.
  3413.                The larger of these are also able to solve matrix equa-
  3414.                tions  (this demonstrates how other programs may be in-
  3415.                tegrated with the package).  The  function  solves  the
  3416.                matrix  equation  AX=B where A is a square matrix and X
  3417.                and B are rectangular ones, A being n by n and X, B be-
  3418.                ing n by m.  
  3419.  
  3420.                     The call formats for IDATE and MTXEQU are 
  3421.  
  3422.                *U IDATE() 
  3423.  
  3424. AnalytiCalc Reference Manual                                   Page 67
  3425.  
  3426.  
  3427.  
  3428.  
  3429.                *U MTXEQ(AA:AA,XX:XX,BB:BB) 
  3430.  
  3431.                where  the  notation AA:AA means two cells at the upper
  3432.                left and lower right edges of matrix A (e.g.  B2:C3 for
  3433.                the  2  X 2 matrix so defined), and the XX:XX and BB:BB
  3434.                notation means the same for the X and B matrices.  This
  3435.                capability  is  used  to solve systems of linear simul-
  3436.                taneous equations and does so with extreme speed.  Note
  3437.                however  that  errors  can  occur  if  the  A matrix is
  3438.                singular.   The  cell  returns  0  if  the  matrix  was
  3439.                singular  and  does  not solve the equation then;  1 is
  3440.                returned if the equation was solved.  
  3441.  
  3442.                     Note  that  matrix A is modified by the call, so a
  3443.                reasonable precaution is to ensure that the  matrix  is
  3444.                reset  by  AnalytiCalc prior to each computation.  This
  3445.                may be done by:  
  3446.            1.  Placing the MTXEQ call in a cell left and down from the
  3447.                A matrix and 
  3448.            2.   Ensuring there are some alphas in each entry in matrix
  3449.                A.  This may be done by placing a  \*C FRC RECALC  into
  3450.                each  cell.   This is a comment and will not affect the
  3451.                number.    However   because   it   contains    alphas,
  3452.                AnalytiCalc  will  then re-compute each number whenever
  3453.                the sheet is computed.  
  3454.  
  3455.                     or 
  3456.  
  3457.                     Using the MOVEV function to copy the real A matrix
  3458.                onto the working one before the MTXEQU call every time.
  3459.                (This  is  the efficient way to do it, as recalculating
  3460.                the constants every time wastes resources.) 
  3461.  
  3462.                     To have the X matrix cells displayed without being
  3463.                modified, it is necessary to have the  cells'  formulas
  3464.                contain  a  self-reference.  The easiest way to achieve
  3465.                this is to place the "formula" P 0 0  into  each  cell.
  3466.                This  effectively will cause display of whatever number
  3467.                is there.  A similar technique may be used  to  set  up
  3468.                matrix A, where the real matrix is elsewhere and formu-
  3469.                las in A are just the P 0 0 type.  The real matrix  may
  3470.                contain  formulas  like  "34.65\D12=%"  to  set  up the
  3471.                desired contents here AND to reset  cell  D12  (in  the
  3472.                work  area)  to the entered value.  The B matrix is not
  3473.                modified by the MTXEQ routine.  A simpler way to handle
  3474.                the  problem  is  to  use the MOVEV function (below) to
  3475.                copy the desired cells  to  a  scratch  A  matrix  from
  3476.                wherever it was, so the scratch matrix may be destroyed
  3477.                without impact on display.  If this is done, the source
  3478.  
  3479. AnalytiCalc Reference Manual                                   Page 68
  3480.  
  3481.  
  3482.  
  3483.                of  the  A  matrix  need  not be specially bollixed up.
  3484.                Several additional functions exist in the  larger  ver-
  3485.                sions  of  USRFCT, the largest of which is designed for
  3486.                use with VAX due to space limitations on PDP11.  
  3487.  
  3488.                *U MOVEV mtxa,mtxb 
  3489.  
  3490.                where  mtxa  and mtxb are matrix specifiers.  This com-
  3491.                mand moves values from mtxa to mtxb  (useful  prior  to
  3492.                calling MTXEQ).  
  3493.  
  3494.                *U MDET mtx 
  3495.  
  3496.                This  function  computes and returns the determinant of
  3497.                matrix mtx (specified as v1:v2  where  v1  and  v2  are
  3498.                upper left and lower right corners of the matrix).  
  3499.  
  3500.                The  next  functions  are implemented in the largest of
  3501.                the USRFCT routines, and presently are limited  to  VAX
  3502.                implementations,  in  which they are present by default
  3503.                unless the build files are changed.  
  3504.  
  3505.                *U MPROD A,B,C 
  3506.  
  3507.                This function will multiply matrix A by matrix B giving
  3508.                matrix C, provided that their dimensions  are  compati-
  3509.                ble.   Note  this  and later functions may be available
  3510.                only on VAX versions of AnalytiCalc.  
  3511.  
  3512.                *U MADDV A,B,C 
  3513.  
  3514.                This  function  adds matrix A to matrix B and stores in
  3515.                matrix C.  All matrices must have the same  dimensions.
  3516.                It  can  be used for adding values in any pairs of rec-
  3517.                tangular regions much faster than a series of sum func-
  3518.                tions would permit.  
  3519.  
  3520.                *U MSUBV A,B,C 
  3521.  
  3522.                This  function subtracts matrix B from matrix A leaving
  3523.                the result in matrix C;  as  above,  matrix  dimensions
  3524.                must be the same.  It also is far faster in subtracting
  3525.                rectangular regions than  numerous  separate  equations
  3526.                would be.  
  3527.  
  3528.                *U MMPYT A,B,C 
  3529.  
  3530.                This function multiplies matrix A-transpose by matrix B
  3531.                and stores the result in matrix C;  dimensions must  be
  3532.                compatible.   Also,  as  in MPROD, matrix C must not be
  3533.  
  3534. AnalytiCalc Reference Manual                                   Page 69
  3535.  
  3536.  
  3537.  
  3538.                the same as either A or B.  In ordinary use,  this  can
  3539.                be  handy  for dot products.  That is, suppose you have
  3540.                two column parts, G10:G50 and R20:R60 and you  want  to
  3541.                form  the  sum  (G10*R20  +  G11*R21 + G12*R22 + ...  +
  3542.                G50*R60) for later use.  In many systems, you  need  to
  3543.                make another column of the G10*R20, etc.  terms and add
  3544.                it up.   Here,  you  can  use  the  MMPYT  function  as
  3545.                *U MMPYT G10:G50,R20:R60,G51:G51  to  form  the sum and
  3546.                store it in cell G51.  (It can be stored anywhere;  G51
  3547.                is chosen just for illustration.) If you have a row and
  3548.                a column to multiply, you use the  MPROD  function  in-
  3549.                stead  of  MMPYT  for  this.   Since this is a built in
  3550.                function, it can be orders of magnitude faster than the
  3551.                separate - column approach.  
  3552.  
  3553.                *U MMPYC A,B,K 
  3554.  
  3555.                This  function  multiplies every element of matrix A by
  3556.                constant K (a  cell  or  accumulator)  and  stores  the
  3557.                result  in  matrix B.  This function is FAR faster than
  3558.                separately multiplying many  cells.   If  you  want  to
  3559.                scale  a  rectangular  region of the sheet by some con-
  3560.                stant, this function can be used to quickly do so, mul-
  3561.                tiplying  each  cell  in  the region by the constant in
  3562.                cell or accumulator K (K can be ANY cell  or  accumula-
  3563.                tor).   Wherever  you need to adjust data by some frac-
  3564.                tion, this function should be used as the  fastest  way
  3565.                of doing it.  
  3566.  
  3567.  
  3568.                *U VARY X,A,W,I,P;Q;R;S;T;U;V;W 
  3569.  
  3570.                (Equation Solving by Iterative Search) 
  3571.  
  3572.                This   function  allows  AnalytiCalc  to  automatically
  3573.                search for solutions to equations over up to  8  dimen-
  3574.                sions.  The operation is that the accumulators named in
  3575.                the fields shown as P;Q;R;S;T;U;V;W (one to  8  may  be
  3576.                specified,  only one is required) are varied by a frac-
  3577.                tion W about their initial values (later scaled down by
  3578.                the  gradient of the change in X) to attempt to get ac-
  3579.                cumulator or cell X to equal  accumulator  or  cell  A.
  3580.                This  is  done for I iterations, where I is another ac-
  3581.                cumulator.  Care should be taken that I is not initial-
  3582.                ized  in  every pass of the spreadsheet, but at most 20
  3583.                iterations will be done in any one pass as a  safeguard
  3584.                in  any  case.  The accumulators given must be indepen-
  3585.                dent variables;  set dependent  ones  or  normalization
  3586.                conditions elsewhere on the sheet for use with calcula-
  3587.                tions.  Any function or set of functions can be entered
  3588.  
  3589. AnalytiCalc Reference Manual                                   Page 70
  3590.  
  3591.  
  3592.  
  3593.                and  the  program will step the accumulators to attempt
  3594.                to find a (local) minimum of the value of (X-A) where X
  3595.                and  A  may be either accumulators or cells.  The other
  3596.                arguments must be accumulators (i.e., named  A  through
  3597.                Z,  though  prior automatic use of X, Y, and Z may con-
  3598.                flict if these are used).   This  function  will  allow
  3599.                iterative  solutions  to  be  found  for situations not
  3600.                soluble  directly,  with  stops  for  inspection  every
  3601.                several  iterations.   The  TE command may be used con-
  3602.                veniently to set the accumulator designated as  I  here
  3603.                without need to modify a cell to do so.  
  3604.  
  3605.                     The  VARY function is initialized by a negative or
  3606.                0 value in the I accumulator (the LOGICAL  one,  not  I
  3607.                itself).   The  equations controlling the variation may
  3608.                appear anywhere in the sheet, and variation  begins  at
  3609.                the initial values set into the varying ACs (P-W in the
  3610.                illustration).  Both the logical X and  A  accumulators
  3611.                may vary, as well.  
  3612.  
  3613.                     As an example, let us suppose we want to solve the
  3614.                equation A=SQRT(B) for B, given  A.   Humans  would  of
  3615.                course  just  square  both  sides,  but in an iterative
  3616.                solution, we would vary B until we found A.  The method
  3617.                used here performs the variations intelligently so that
  3618.                we actually approach the correct value  asymptotically;
  3619.                the  signal  we  have  a solution is that the variation
  3620.                stops.  To set this up, we might  enter  the  following
  3621.                equations  in  a  row  or column (or anywhere actually;
  3622.                order doesn't matter) in the sheet:  
  3623.  
  3624.                I=-1.\A=55.\P=12.\*C Set up to initialize 
  3625.                            with negative I, initial guess 
  3626.                            12., and desired value 55.  
  3627.                W=1.\*C Set "step scale" 
  3628.                P+0.\*C Display P accumulator on screen 
  3629.                B=SQRT(P)\*C Enter equation relating B, P 
  3630.                *U VARY B,A,W,I,P 
  3631.  
  3632.                Now we go back to the first equation, since the desired
  3633.                value in A (55.) has been set and the initial guess for
  3634.                SQRT(55.) has been entered (12.) and we may now set the
  3635.                number of iterations desired to drive the  calculations
  3636.                to solve the equation 
  3637.                B=A (which amounts to B=55.) 
  3638.                (which is what the VARY function does), by varying P to
  3639.                control B.  The idea here is that we can control P, but
  3640.                B  is  an  ARBITRARY  function of P (and possibly other
  3641.                AC's) and we will vary the independent AC's like  P  to
  3642.                find  what  THEY  need  to  be to arrive at the desired
  3643.  
  3644. AnalytiCalc Reference Manual                                   Page 71
  3645.  
  3646.  
  3647.  
  3648.                dependent "goal" values.  Here we are solving  B=A,  or
  3649.                B=55., or SQRT(P)=55.  and finding P in this way.  
  3650.  
  3651.                     In the first equation we now enter 
  3652.  
  3653.                I=10.\*C Enter some number of iterations 
  3654.                          to search for between displays.  
  3655.  
  3656.                and  for  every display, we will see how P varies since
  3657.                we are displaying P in one of the cells.  It will  con-
  3658.                verge on the square root of 55.  (which is 7.416) after
  3659.                some iterations.  We may just use the  TE  command  in-
  3660.                stead  to  set  the  I accumulator to avoid some of the
  3661.                complexity of messing with cells on the sheet.  We then
  3662.                use  the R (Recalculate) command after the TEst command
  3663.                to cause the solving to begin.  
  3664.  
  3665.                     Note that we could have more than just accumulator
  3666.                P varying and could have much more  complex  functions.
  3667.                Also,  both A and B could be functions of any or all of
  3668.                these accumulators.  Matrix computations may  be  used,
  3669.                or   any   other   functions   available   through  the
  3670.                spreadsheet, and the equations may be entered  anywhere
  3671.                on  the  sheet.  In this way, some quite powerful sorts
  3672.                of solutions to equations may be found.  The philosophy
  3673.                of  this  is  that if you know enough algebra to set up
  3674.                the equations for a problem (the hard  part),  you  can
  3675.                set  them up so the spreadsheet can solve them directly
  3676.                yourself, if there is a simple way to do so.  If  there
  3677.                isn't,  and if you can express the desired result as an
  3678.                equation, the  AnalytiCalc  program  can  do  iterative
  3679.                searching to try and solve the problem for you, varying
  3680.                up to 8 accumulators to do so.  If you really  want  to
  3681.                search for a situation in which several cells are close
  3682.                to several others, just make up an additional cell that
  3683.                is  the  "summed distance" between the desired targets.
  3684.                For example, if you want to arrive at a solution  where
  3685.                cell  B20 should approach B30, D25 should approach D35,
  3686.                and cell X15 should  approach  cell  AQ5,  make  2  new
  3687.                cells.   One  should be zero, and the other will have a
  3688.                formula that looks like 
  3689.  
  3690.                (B20-B30)**2+(D25-D35)**2+(X15-AQ5)**2 
  3691.  
  3692.                or  a  simple  variation, perhaps using multiplying in-
  3693.                stead of **2 as was done here.  This will  produce  the
  3694.                desired results, PROVIDED that the cells depend somehow
  3695.                on the accumulator values you are varying.  
  3696.            There are 2 more functions for the USRFCT.F40 sources which
  3697.                permit access  to  formulae  and  allow  more  flexible
  3698.  
  3699. AnalytiCalc Reference Manual                                   Page 72
  3700.  
  3701.  
  3702.  
  3703.                command  procedures.   These  functions exist only in a
  3704.                variant of  AnalytiCalc-VM,  not  in  the  versions  of
  3705.                AnalytiCalc  using work files.  This is because support
  3706.                in the XQTCMD module was needed  for  the  XQTCM  func-
  3707.                tions.  
  3708.  
  3709.                     The  function  *U XQTCM command  will  execute the
  3710.                command (terminated by the end-of-line), with any  com-
  3711.                mand except X or K permitted, from inside a cell.  This
  3712.                allows command files driven from cells to control  mov-
  3713.                ing  data,  etc.  It is suggested that cells containing
  3714.                these references in command files have the last command
  3715.                in the file set the cell format to [A] so that the com-
  3716.                mand execution will be once only, unless repeated  com-
  3717.                mands are desired.  This function may not be present on
  3718.                overlaid versions of AnalytiCalc.  The 8088 version has
  3719.                it.  
  3720.  
  3721.                     The function "*U STRVL V1,start;len" will return a
  3722.                value that is made from up to 8 characters in the  FOR-
  3723.                MULA  of  cell V1 (where V1 is any cell name), starting
  3724.                at character "start" and  for  "len"  characters.   The
  3725.                value  is  computed  such  that a numeric sort on these
  3726.                values is equivalent to an alpha sort on the  formulas;
  3727.                the  characters are multiplied from the left by 128 and
  3728.                the next ASCII value is added.  This  function  may  be
  3729.                combined  with the DS commands to sort on text, or with
  3730.                the XQTCM functionality to  drive  a  slower  but  more
  3731.                thorough sort on values.  
  3732.  
  3733.                     The function "*U HERE" will return the current lo-
  3734.                cation  on  the  matrix.   The  normal  result   is   a
  3735.                hash-coded  address of the physical cell pointed to, in
  3736.                the % accumulator, and the column and row in  accumula-
  3737.                tors  T  and U respectively.  The row number is up by 1
  3738.                (as the X,Y accumulators are at start of  cell  evalua-
  3739.                tion)  to  account  for accumulator storage.  Also, the
  3740.                flags for manual display update and manual  recalculate
  3741.                are  returned  in  accumulator  V.  The 4 bit being set
  3742.                means manual view is set on, and the 2 bit means manual
  3743.                recalculate is on.  The W and Y accumulators return the
  3744.                current maximum column and row used  also.   These  are
  3745.                designed to make it easy to use the IR command (Inplace
  3746.                Relocate) to go over only cells in use.  
  3747.  
  3748.                     The  function  *U  FFTFW and the function *U FFTRV
  3749.                perform Fast Fourier  Transforms  in  the  forward  and
  3750.                reverse  (inverse)  directions  on  the  given range of
  3751.                data.  The largest power of 2 of data points less  than
  3752.                or   equal   to   the   given   range  is  used  and  a
  3753.  
  3754. AnalytiCalc Reference Manual                                   Page 73
  3755.  
  3756.  
  3757.  
  3758.                one-dimensional real FFT is performed.  This is  useful
  3759.                for digital filters and the like.  The input values are
  3760.                replaced by their FFT so it is best to work with values
  3761.                copied  from the real inputs (use the *U MOVEV function
  3762.                to move the values before use).  
  3763.  
  3764.                     The  function  *U  LINEF  Vy:Vy,Vx:Vx (with the Vx
  3765.                range optional) fits a line to  the  input  range.   It
  3766.                will  use  the Vx range as the X coordinate if supplied
  3767.                or will compute a range if none is supplied  using  the
  3768.                cell coordinates.  It computes the line equation Y=mX+B
  3769.                and returns the slope m in accumulator U and the inter-
  3770.                cept B in accumulator T.  The value returned in accumu-
  3771.                lator % from the function is the Y  fit  error  of  the
  3772.                line fit. The W accumulator returns the correlation co-
  3773.                efficient of X and Y.
  3774.   *XV filename V1 
  3775.   *XF filename V1        The *X class commands are for sheet linkages. 
  3776.                *XF  loads  a  Formula  from another saved spreadsheet,
  3777.                while *XV loads a Value (normally  from  a  NUMERICALLY
  3778.                saved  sheet).   They  look  in  the given file for the
  3779.                named variable in the saved sheet and place the formula
  3780.                or  value in the current position of the current sheet.
  3781.                Note the *P commands may be used to reset the  position
  3782.                if  it  is desired not to overwrite the current formula
  3783.                in the case of the *XF command;  the  *XV  command  as-
  3784.                sumes the sheet was saved numerically and does not mod-
  3785.                ify the formula.  Note that each *X class command  gets
  3786.                1 number or formula.  
  3787.  
  3788. AnalytiCalc Reference Manual                                   Page 74
  3789.  
  3790.  
  3791.  
  3792.                  AnalytiCalc File Interface Functions
  3793.  
  3794.       Command  level functions are given as FILcccccc where ccc is the
  3795.  actual command.  Equivalent functions are available from cells  using
  3796.  the  syntactic form *U DBcccccc arguments (where the "arguments" part
  3797.  is any arguments, generally some required.) 
  3798.  
  3799.       Some  extra  optional  VAX functions exist that allow regions of
  3800.  the sheet to come from or go to sequential or random files to or from
  3801.  some range of cells.  
  3802.  
  3803.       The  following  commands  exist  (the  "*U DB"  or  the "FIL" is
  3804.  omitted:) 
  3805.  
  3806.  
  3807.  
  3808.    OPINS range filename 
  3809.           Open  input  sequential  on filename for cells in range When
  3810.           the input file is open and any operation causes  a  read  of
  3811.           the  cell, the FORMULA will be taken from the file and used.
  3812.           If the file is opened with the OPINU  option  (for  Update),
  3813.           then  when  the FORMULA of the cell is written, it will also
  3814.           write to the file.  The OPINU option applies only to  random
  3815.           access  files.   Initially  both  input and output reads are
  3816.           disabled (ENAINP and ENAOUT enable them).  When a sequential
  3817.           file  (or  device such as a mailbox, pipe, or communications
  3818.           line) is used for input, it is  advantageous  to  read  data
  3819.           into a range once, then disable input/output again, to allow
  3820.           it to be handled between these  commands.   The  EDTINP  and
  3821.           FMTOUT commands are designed to do this to make it easier to
  3822.           use AnalytiCalc for a filter between sequential files.  
  3823.    OPINR range filename 
  3824.           Open input random on filename for cells in range 
  3825.    OPINU range filename 
  3826.           Open range for update on filename for read and write as ran-
  3827.           dom access.  
  3828.    CLSINP 
  3829.           Close input 
  3830.    CLSOUT 
  3831.           Close output 
  3832.    OPOUTS range filename 
  3833.           Open output sequential from range cells to filename 
  3834.    OPOUTR range filename 
  3835.           Open output random from range on filename 
  3836.    ENAINP 
  3837.           Enable input file readin (initially disabled) 
  3838.    ENAOUT 
  3839.           Enable output write (initially disabled) 
  3840.    DISINP 
  3841.           Disable input area readin 
  3842.  
  3843. AnalytiCalc Reference Manual                                   Page 75
  3844.  
  3845.  
  3846.  
  3847.    DISOUT 
  3848.           Disable output write 
  3849.    EDTINP range 
  3850.           Enables  input  and  output  and, for each cell in the given
  3851.           range,  reads  and  writes  the  cell,  allowing  the   file
  3852.           read/writes  to  take effect.  Each cell is flagged as valid
  3853.           but of text type;  the DF command must be used to reset  any
  3854.           that  should be treated as computable.  Input and output are
  3855.           disabled on completion of the command.  
  3856.    FMTOUT range 
  3857.    VALOUT range 
  3858.           Enables  input  and  output  and  for each cell of the range
  3859.           takes the VALUE of the cell, reads the cell, sets it of text
  3860.           type,  and  writes  the  text equivalent of its value to the
  3861.           cell.  In the FMTOUT command the cell's  display  format  is
  3862.           used  for  the  conversion.   In  the VALOUT command a large
  3863.           builtin format is used to preserve all  significant  digits.
  3864.           Spaces  are  discarded prior to output.  Cells are left con-
  3865.           taining textual data corresponding to their numeric  values,
  3866.           stored in the formulae.  The DF command may be used to reset
  3867.           these cells to numeric types if desired.  Conversion  errors
  3868.           are ignored.  Input and output are disabled on completion of
  3869.           the command.  
  3870.    CMPFRM V1:V2[,V3:V4] 
  3871.           Compares  two  formulas.   It returns, in the % accumulator,
  3872.           the index of the formula in cell V2 in the formula  in  cell
  3873.           V1.   Lengths  used are those of both formulas UNLESS the V3
  3874.           and V4 cell arguments are seen.  In that case the  value  of
  3875.           V3  will be used as the length of the formula for V1 and the
  3876.           value of V4 will be used as the length of cell V2.   If  ei-
  3877.           ther  value  in  V3 or V4 is outside the range 1 to 109 both
  3878.           values in V3 and V4 will be ignored.  Also on output  the  W
  3879.           accumulator  will  be set to -1.  if V1 is lexically earlier
  3880.           than V2, 0.  if they are lexically equal, and +1.  if V1  is
  3881.           lexically later than V2.  
  3882.    LENFRM V1:V2 
  3883.           returns  the  length of the formula for cell V1 in the % ac-
  3884.           cumulator and in cell V2 IF CELL V2 IS VALID.  Otherwise the
  3885.           cell  specified  in V2 is ignored, though it must be present
  3886.           in the command or function.  
  3887.    TRMFRM V1:V2,V3,V4 
  3888.           Reads  the formula in V1 and uses V3 and V4 as start and end
  3889.           byte numbers within it.  It returns to V2 the  formula  that
  3890.           is  between the start and end bytes, trimming the V1 formula
  3891.           into V2 by chopping out the undesired parts.  The find  sub-
  3892.           string  function  CMPFRM can be used to find delimiter bytes
  3893.           if absolute columnar formatting is not desired.  
  3894.  
  3895.  
  3896.  
  3897.  
  3898. AnalytiCalc Reference Manual                                   Page 76
  3899.  
  3900.  
  3901.  
  3902.       Associated  DBxxxxxx  and FILxxxxxx commands both exist and have
  3903.  the same syntax.  
  3904.  
  3905.       These  commands  give  a means for having a spreadsheet template
  3906.  operate on files (treated as formula inputs or  outputs)  from  other
  3907.  independent  programs.   Random files have 128 byte record length and
  3908.  unique indices computed from the relative position in the range being
  3909.  used.   Sequential files are variable length but never have more than
  3910.  110 bytes (formula size) in them.  Interpretation of formulas  is  up
  3911.  to the spreadsheet.  
  3912.  
  3913.       On sequential reads, data is read until EOF and then the file is
  3914.  closed.  Input is treated as a "last step" before returning the  for-
  3915.  mula  to  the  main program and just overwrites any internally stored
  3916.  formula.  A dummy  edit  will  enter  the  file  data  into  internal
  3917.  storage.   On  output,  file  write  and internal storage both occur.
  3918.  Open failure just leaves the files closed.  
  3919.  
  3920.       "range"  means  v1:v2,  a  full  2 dimensional matrix range with
  3921.  upper left corner and lower right corner cells  specified.   Calcula-
  3922.  tion  order  is unaffected and generally is across fast, down slower,
  3923.  like a TV raster scan.  
  3924.  
  3925.       The  functions for CMPFRM and LENFRM are provided in addition to
  3926.  the other functions here to allow the spreadsheet to more easily  lo-
  3927.  cate  and  parse text in data coming from generic applications.  Note
  3928.  that the {cell constructs can be used (possibly with an  *U  XQTCM  E
  3929.  function)  to  move pieces of text around in conjunction with copies.
  3930.  The CMPFRM function can help find out if the reply from the  applica-
  3931.  tion is what is desired and already built-in conditional handling can
  3932.  be used for acting on this information.  
  3933.  
  3934.       As in all these functions, CMPFRM and LENFRM have the forms 
  3935.  FILCMPFRM and 
  3936.  FILLENFRM interactively, and 
  3937.  *U DBCMPFRM and 
  3938.  *U DBLENFRM in formulas (with the remaining arguments included.) 
  3939.  
  3940.  
  3941.  
  3942.       These   functions  are  meant  to  allow  some  "connection"  of
  3943.  AnalytiCalc with arbitrary other applications by batch files  or  EX-
  3944.  ECed  subprocesses,  where AnalytiCalc can produce inputs for another
  3945.  application's console input and accept another  program's  output  as
  3946.  its input in an intelligent and controllable way.  
  3947.  
  3948.       Also the string functions provided can be useful for certain ap-
  3949.  plications independent of file I/O.  However all these functions  are
  3950.  in  overlays  (one  for  commands,  another for functions) and so can
  3951.  
  3952. AnalytiCalc Reference Manual                                   Page 77
  3953.  
  3954.  
  3955.  
  3956.  cause some thrashing in AnalytiCalc - 256K.  The liklihood of this is
  3957.  small in the 320K version.  
  3958.  
  3959.  
  3960.                          -ADDITIONAL FEATURES-
  3961.  
  3962.       CALC  is similar to FORTRAN with respect to operator precedence.
  3963.  Blanks may occur anywhere on a command  line  without  effect  except
  3964.  after  a  single  quote mark used to specify a single ASCII character
  3965.  constant.  CALC extends the  ANSI  FORTRAN  syntax  by  allowing  the
  3966.  following:  
  3967.  
  3968.  
  3969.        1.  multiple assignments on one line, for example 
  3970.  
  3971.           I=J=K=812 
  3972.        2.  Unary + and unary - are allowed, for example 
  3973.           2*-3 
  3974.           +2+-7 
  3975.           -2**4 
  3976.           are  all legal.  The last expression evaluates to 16 because
  3977.           the unary - has a higher precedence than exponentiation.  
  3978.        3.  exponentiation may be indicated by using !  as well as ** 
  3979.  
  3980.       If any of the declarations are entered (such as *INTEGER) and no
  3981.  argument to this command is given, then CALC will print out the vari-
  3982.  ables  that  have been assigned that data type.  Note that a variable
  3983.  can be assigned to different data types using such commands and still
  3984.  not  be assigned a value.  If you attempt to output the value of such
  3985.  a variable, an error message will result.  
  3986.  
  3987.  
  3988.                               USAGE NOTES
  3989.    1.  When you iterate on a file by a call such as 
  3990.             *@REPEAT X 
  3991.     then note that 
  3992.      A)  X  must have been set to a positive value when the command is
  3993.           executed or else the file will not be executed.  
  3994.      B) If the file of commands does not change the value of the vari-
  3995.           able X you will enter an infinite loop.  You can  explicitly
  3996.           set X to a non-positive value, use the *Z command to zero it
  3997.           (if it is not %), or include a 
  3998.           *R 
  3999.           command  to  give you a chance to reset the variable and get
  4000.           out of the loop.  
  4001.      C)  *E and *S will allow you to exit from the command file REPEAT
  4002.           but will not of themselves prevent repetitions.  
  4003.      D)  Entering  constants  echo  on  the  terminal  (assuming *V is
  4004.           properly set) and can change the value and type of the vari-
  4005.           able  %.   This  is  important  to  remember when using % to
  4006.  
  4007. AnalytiCalc Reference Manual                                   Page 78
  4008.  
  4009.  
  4010.  
  4011.           control the iteration of a file.  
  4012.    2.  In FORTRAN, 
  4013.           -A**2 is the same as -(A**2) 
  4014.      with CALC, 
  4015.           -A**2 is the same as (-A)**2 (just like SNOBOL!) 
  4016.    3.  If R and A are positive reals and I is a positive integer, some
  4017.           compilers like RSX-11M's  F4P  won't  allow  (at  run  time)
  4018.           evaluation of 
  4019.           (-I)**R 
  4020.           (-A)**R 
  4021.    4.  Under RSX-11M F4P you will find 
  4022.           2**.5 to have value 1 
  4023.      while 
  4024.           2.**.5 has value 1.41421356237310 
  4025.    5.   10E10  is  a  hexadecimal constant (integer) while 10.E10 is a
  4026.           real.  
  4027.  
  4028. AnalytiCalc Reference Manual                                   Page 79
  4029.  
  4030.  
  4031.  
  4032.                               Appendix A
  4033.  
  4034.   ASCII  CALC   ASCII  CALC   ASCII  CALC   ASCII  CALC
  4035.   CODE   PRINTS CODES  PRINTS CODE   PRINTS CODE   PRINTS
  4036.   ----   ------ -----  ------ ----   ------ ----   ------
  4037.  
  4038.     0    ^      32            64     @      96     `
  4039.     1    ^!     33     !      65     A      97     a
  4040.     2    ^"     34     "      66     B      98     b
  4041.     3    ^#     35     #      67     C      99     c
  4042.     4    ^$     36     $      68     D      100    d
  4043.     5    ^%     37     %      69     E      101    e
  4044.     6    ^&     38     &      70     F      102    f
  4045.     7    ^'     39     '      71     G      103    g
  4046.     8    ^(     40     (      72     H      104    h
  4047.     9    ^)     41     )      73     I      105    i
  4048.    10    ^*     42     *      74     J      106    j
  4049.    11    ^+     43     +      75     K      107    k
  4050.    12    ^,     44     ,      76     L      108    l
  4051.    13    ^-     45     -      77     M      109    m
  4052.    14    ^.     46     .      78     N      110    n
  4053.    15    ^/     47     /      79     O      111    o
  4054.    16    ^0     48     0      80     P      112    p
  4055.    17    ^1     49     1      81     Q      113    q
  4056.    18    ^2     50     2      82     R      114    r
  4057.    19    ^3     51     3      83     S      115    s
  4058.    20    ^4     52     4      84     T      116    t
  4059.    21    ^5     53     5      85     U      117    u
  4060.    22    ^6     54     6      86     V      118    v
  4061.    23    ^7     55     7      87     W      119    w
  4062.    24    ^8     56     8      88     X      120    x
  4063.    25    ^9     57     9      89     Y      121    y
  4064.    26    ^:     58     :      90     Z      122    Z
  4065.    27    ^;     59     ;      91     [      123    {
  4066.    28    ^<     60     <      92     \      124    \
  4067.    29    ^=     61     =      93     ]      125    }
  4068.    30    ^>     62     >      94     ^      126    ^
  4069.    31    ^?     63     ?      95     _      127
  4070.  
  4071.  
  4072.  
  4073.             Interactive Calc in the AnalytiCalc environment
  4074.  
  4075.       Calc  runs as part of AnalytiCalc to do much of the math.  The K
  4076.  command drops into straight Calc and  it  works  as  described  here.
  4077.  There are a few additions however.  
  4078.  
  4079.       First,  Calc can access all the variables on the sheet (names a1
  4080.  and up), which may be up to 8 bytes  long.   However,  while  it  can
  4081.  examine or set any of these, the spreadsheet recomputes them from its
  4082.  
  4083. AnalytiCalc Reference Manual                                   Page 80
  4084.  
  4085.  
  4086.  
  4087.  disk based formula file when re-entered by the *E command.  To modify
  4088.  this  file,  the "current position" in the physical display sheet may
  4089.  be set by answering the prompts after giving the  *P  command.   Then
  4090.  the  current  display value (contents of the "%" variable) may be en-
  4091.  tered into the disk file by executing the *W command.  Numerous other
  4092.  manipulations are possible, and by setting the view level to 3 (*V 3)
  4093.  it is possible to debug a command file that drives a spreadsheet cell
  4094.  from  interactive mode (by tracing through its' operation to see what
  4095.  it is doing).  All interactive Calc commands work also from  indirect
  4096.  files.   The  physical location is clamped to legal values.  Note too
  4097.  that any unused cells of the sheet may be used as  scratch  accumula-
  4098.  tors.   However,  they may not assume any types of multiple precision
  4099.  numbers, as they are all 8 bytes long.  The internal expression stack
  4100.  is  40  tokens deep, so very complex expressions may have to be split
  4101.  into pieces to work.  Error messages will be shown if  this  happens;
  4102.  they are placed on the top line of the screen.  
  4103.  
  4104.  
  4105.  
  4106.  
  4107.                     The AnalytiCalc GRAPHICS System
  4108.  
  4109.                                 ACGRAF
  4110.  
  4111.             GRAPHICS INTERFACE AND OUTPUT FROM ANALYTICALC
  4112.  
  4113.  
  4114.  
  4115.                              Introduction
  4116.  
  4117.       The  AnalytiCalc  system  uses a separate program to provide its
  4118.  graphics output, permitting  easy  tailoring  to  different  graphics
  4119.  devices.   The  routine supplied uses a character graphics subroutine
  4120.  (GHASP) to produce histograms and scatter  plots  from  any  rows  or
  4121.  columns  of a saved (numerically saved, that is) sheet which has been
  4122.  saved via the PPN or PDN commands.  The output is  printed  normally.
  4123.  However,  users  with other devices may easily modify this program to
  4124.  insert their own favorite graphics output device output into the pro-
  4125.  gram.  There are several options to govern plotting, and one plot per
  4126.  command is produced.  Once a saved sheet is generated, many plots can
  4127.  be made from it without reentering the sheet.  
  4128.  
  4129.       An advantage of this approach is that the address space consumed
  4130.  by the graphical routines is not taken from the spreadsheet.   Graph-
  4131.  ics  may  be  handled  with  a fair degree of transparency by command
  4132.  files, or even by spawned commands.  Another advantage is that  addi-
  4133.  tional  graphics  devices may be added easily without modification to
  4134.  the spreadsheet.  The current  version  uses  character  graphics  to
  4135.  permit  usable  displays  even on monochrome monitors.  (Note:  there
  4136.  are several additional graphics programs supplied which are given  in
  4137.  
  4138. AnalytiCalc Reference Manual                                   Page 81
  4139.  
  4140.  
  4141.  
  4142.  source   in   BASIC.   These  provide  additional  functionality  not
  4143.  described here but allow line  charts,  bar  charts,  piecharts,  and
  4144.  numerous other options.) 
  4145.  
  4146.  
  4147.  
  4148.       Getting Started:  
  4149.  
  4150.       Run  AnalytiCalc  (Type  ANALY)  and create your spread sheet to
  4151.  your liking.  When it is set, use the following commands:  
  4152.  
  4153.      L A1    go to cell A1 (top left of sheet
  4154.      PPN     Put out physical sheet numerically.
  4155.  
  4156.  When  AnalytiCalc  asks for a filename, give one which describes your
  4157.  file well (with a file  type)  followed  by  return.   Example:   My-
  4158.  file.num 
  4159.  
  4160.       When  AnalytiCalc asks you for maximum displacements, enter 0 in
  4161.  both cases (equivalent to telling it to save everything).  
  4162.  
  4163.       When done, you may use the X command to exit AnalytiCalc.  
  4164.  Now run ACGRAF by typing ACGRAF 
  4165.  When ACGRAF first starts, it asks for an output dataset.  This may be
  4166.  any file or device on the system.  If CON:  is used  as  output  (the
  4167.  terminal),  or  if  the filename chosen begins with the letters "TT",
  4168.  the graph will be scaled to fit on a terminal screen.   Otherwise  it
  4169.  will  be  sized to fit a sheet of (normally 132 column) printer paper
  4170.  and will have some extra  statistical  information  about  the  plot.
  4171.  When  ACGRAF runs, it will ask for a command line.  A typical command
  4172.  to give a scaled plot of column H from row 1 to row 30 would be 
  4173.  
  4174.  Enter plot command>NN myfile.num H1:H30 [S] 
  4175.  
  4176.  
  4177.       Note  that the rows and columns are referred to exactly s on the
  4178.  sheet itself.  The initial NN could be  LL  or  LN  or  PP  or  other
  4179.  letters,  but L in column 1 takes the logarithm of the numbers in the
  4180.  first (in the example the only) range of numbers selected, and  L  in
  4181.  column  2  takes  the log of the numbers in the second range.  A P is
  4182.  used instead of an N where the values displayed should start from  0.
  4183.  rather than from the lowest value in the region selected.  
  4184.  
  4185.       Should  the  range  to be plotted include only POSITIVE numbers,
  4186.  make the first 2 letters P's.  This will ensure the scale starts at 0
  4187.  rather than at the minimum positive value selected.  The command line
  4188.  would then look like:  
  4189.  
  4190.  Enter plot command>PP myfile.num H1:H30 [S] 
  4191.  
  4192.  
  4193. AnalytiCalc Reference Manual                                   Page 82
  4194.  
  4195.  
  4196.  
  4197.       Scatter  plots  plot  entries  in  the  first range against cor-
  4198.  responding entries in the second  range  selected.   One  dimensional
  4199.  plots  are up to 100 bins wide and scatter plots are up to 50 bins by
  4200.  50 bins.  Height of histograms is Scaled to fit a  page  if  the  [S]
  4201.  form is used and will Vary to whatever is needed if the [V] character
  4202.  is used.  Widths of plots are less than 100 (or 50) if the number  of
  4203.  entries plotted are less than those dimensions;  if the number of en-
  4204.  tries plotted is greater, it will be scaled to  the  50  or  100  bin
  4205.  maxima  (which  derive from paper size mainly).  If the option [H] is
  4206.  chosen, the plot will be Hacked off at one page, but scaled as if the
  4207.  [V] Vary option were specified.  
  4208.  
  4209.  
  4210.       SYNTAX AND USAGE:  
  4211.  
  4212.       This program is designed to allow an interactive user to enter a
  4213.  single command line to the program which  it  will  parse  and  allow
  4214.  graphic  output from AnalytiCalc saved spread sheets.  The assumption
  4215.  made is that the sheet has been saved with the PPN  or  PDN  command.
  4216.  The  filename  must  appear  in the command line and variables in the
  4217.  file (named AS THOUGH THE CURSOR HAD BEEN IN CELL A1 WHEN THE  PPN  /
  4218.  PDN  WAS  DONE)  may  be  histogrammed or scatterplotted against each
  4219.  other.  
  4220.  
  4221.  A  FORTRAN  plot  package for ordinary printers will be used for this
  4222.  version.  Other routines may be  readily  used  as  replacements  for
  4223.  specific  graphics  output  devices.   There  is  a document supplied
  4224.  PCSAVFMT.TXT which will give the format used to save AnalytiCalc/Por-
  4225.  taCalc  files to simplify reading them in.  The popular VisiCalc (tm)
  4226.  DIF format was NOT used in this program because it cannot encode  the
  4227.  variety of display formats available.  The format chosen was rather a
  4228.  straight ASCII format permitting almost  any  language  to  read  the
  4229.  saved  files with a minimum of grief, and which permits editing saved
  4230.  sheets with a  normal  text  editor.   (The  fields  are  even  comma
  4231.  separated to make reading in with BASIC easier.) 
  4232.  
  4233.  Input syntax:  
  4234.  PP or NN or LL filename.ext V1:V2 [c] V3:V4 +switches 
  4235.  where 
  4236.  
  4237.       an  L  in  columns  1 or 2 takes log of 1st or 2nd range numbers
  4238.  (base 10), a P indicates Positive numbers (so 0 is  included  in  the
  4239.  range  to  be plotted and the plot starts at 0.  and increases rather
  4240.  than starting at the minimum observed value for an  initialized  cell
  4241.  in  the saved sheet), and N means Normal, i.e., neither of the above;
  4242.  the minimum and maximum coordinates are taken as min and  max  values
  4243.  in the set of values to be plotted, 
  4244.  
  4245.       filename.ext  appears  at  the start of the command line after a
  4246.  space and with a space following it and is a valid RSX  or  VMS  file
  4247.  
  4248. AnalytiCalc Reference Manual                                   Page 83
  4249.  
  4250.  
  4251.  
  4252.  speciciation  (the  same  as was given to AnalytiCalc in the PP or PD
  4253.  command that saved the sheet normally).  
  4254.  
  4255.       V1:V2  and V3:V4 are ranges.  V3:V4 is optional and its presence
  4256.  implies a scatter plot.  These ranges must  be  either  a  row  or  a
  4257.  column  or part of them.  If only range V1:V2 is present, a histogram
  4258.  will be done using the Scale option of GHASP to fit the plot  onto  a
  4259.  page.   The plot will be set up for 100 bins horizontal, 50 vertical,
  4260.  or the number of entries to be plotted, whichever is less.  
  4261.  
  4262.       If  the  V3:V4 range exists, the character Q in the [c] position
  4263.  (the [] are required) will result in a "density" plot  in  which  the
  4264.  program  will  attempt to print darker in filled bins.  This is crude
  4265.  and the default is to use a 2 digit number.  Again, plot size will be
  4266.  scaled  to  50  by  50 bins.  For histograms, the character S implies
  4267.  Scale the plot to fit one sheet of paper,  the  character  H  implies
  4268.  Hack  the  plot  off  at  one sheet, and the character V implies Vary
  4269.  height, using as many sheets of paper as needed  to  plot  the  data.
  4270.  The  character  S should be used for "normal" scatter plots (in which
  4271.  number of entries in a scatter plot "bin" is represented as a  number
  4272.  or character).  
  4273.  
  4274.       To use ACGRAF from inside AnalytiCalc, use the $ command to pass
  4275.  the command line to the system;  this will allow graphics to be  done
  4276.  without  leaving  the AnalytiCalc environment.  This can be done from
  4277.  an indirect file driving AnalytiCalc also, without special  interven-
  4278.  tion, using normal DOS redirection commands.  
  4279.     Switches:
  4280.     +Hnnn    If present, sets Height to nnn characters.
  4281.     +Wnnn    If present, sets Width to nnn characters.
  4282.  These override any defaults.
  4283.  
  4284. AnalytiCalc Reference Manual                                   Page 84
  4285.  
  4286.  
  4287.  
  4288.                               Appendix B
  4289.                 Discussion of Storage Allocation Issues
  4290.  
  4291.  
  4292.                      Storage Allocation Discussion
  4293.  
  4294.       If  you  use  AnalytiCalc-PC, the storage needed per cell in the
  4295.  workfile is 10 bytes per cell, and for formulas, 12 bytes of  formula
  4296.  go  into  every 16 bytes of workfile (the remainder is for accounting
  4297.  overhead).  Thus, for an 18,000 cell sheet, 180K bytes is the maximum
  4298.  useful  value  file  size, and 288K bytes would permit a 12 character
  4299.  formula for each cell, while 2592K bytes would give  every  cell  108
  4300.  characters  and  is  the maximum useful size.  (You can allocate more
  4301.  memory to allow 109 characters per cell, but  this  usually  will  be
  4302.  mostly  wasted.) Since a symbol table algorithm is used, sizes may be
  4303.  as small as desired.  If the size chosen is less than the memory  al-
  4304.  location  built  in (1K is guaranteed to be), no files will be opened
  4305.  and cells will be stored in memory only.  Note that if value and for-
  4306.  mula file sizes are given negative, a slower but sometimes more effi-
  4307.  cient packing will be done of the file.  The workfiles are opened  in
  4308.  one's  default device at the time of running the program.  The "slow"
  4309.  algorithm picks a diskfile page to use by taking the cell number mod-
  4310.  ulo the number of pages in the file.  The "fast" one picks a diskfile
  4311.  page to use by taking the position in the total  sheet  (columns  in-
  4312.  creasing  fastest)  and making the number of cells in a diskfile page
  4313.  vary as number in the sheet divided by  the  size  of  the  diskfile.
  4314.  Thus,  cells  close to one another on the sheet are kept close on the
  4315.  disk file.  This can overflow a disk page if too  many  cells  for  a
  4316.  page  are  used close to each other.  Therefore, the program will ask
  4317.  you how many rows and columns you propose to use for purposes of disk
  4318.  clustering.   If  the "fast" algorithm is used, the disk page will be
  4319.  chosen as (cell address)*(number of disk pages  total)/(size  of  the
  4320.  total  sheet  you  said you'd use, clamped to the max physical size).
  4321.  If you say you'll use a small area, cells will be  scattered  better.
  4322.  If you use beyond the area you said, disk pages are chosen in modular
  4323.  fashion.  Therefore, if you run out of room in  a  file,  try  either
  4324.  varying  the  size  for allocation, or adding space to the files.  If
  4325.  you give the exact size you're really  using,  the  "fast"  algorithm
  4326.  will equally divide disk pages among cells on the screen you're using
  4327.  for rectangular use.  The size question is ignored if the "slow"  al-
  4328.  gorithm  is used, since that algorithm equipartitions without needing
  4329.  to know the size used.  Typical values to use for the number of  rows
  4330.  and  columns  you intend to use for small problems might be 16 by 16.
  4331.  The program asks how big to make the disk  based  files  next,  given
  4332.  that it now knows how to allocate cells to the files.  
  4333.  
  4334.       There  are  two effects of importance here.  First, if you don't
  4335.  allocate enough space, scratch files may overflow and you'll have  to
  4336.  save  the  sheet and rerun with bigger files.  Second, if the scratch
  4337.  files are TOO big, the program will waste  time  switching  pages  in
  4338.  
  4339. AnalytiCalc Reference Manual                                   Page 85
  4340.  
  4341.  
  4342.  
  4343.  memory  unnecessarily.  Therefore, when you tell AnalytiCalc how much
  4344.  space you intend to use, it prints out the sizes of files needed  AS-
  4345.  SUMING  that  you will fill in EVERY cell in the range indicated, and
  4346.  that formulas are 12 or less characters long.  If you use less cells,
  4347.  both  files may be shorter.  If formulas are longer, the formula file
  4348.  needs to be made bigger.  The program won't actually go out  to  disk
  4349.  unless  the  files  are  bigger  than its in memory buffers, so don't
  4350.  worry about that condition.  The suggested sizes are usually  a  good
  4351.  guess.   (These  are printed on the screen after you tell it how many
  4352.  rows and columns you intend to use.) 
  4353.  
  4354. AnalytiCalc Reference Manual                                   Page 86
  4355.  
  4356.  
  4357.  
  4358.                               Appendix C
  4359.                      320K Version of AnalytiCalc 
  4360.  
  4361.  
  4362.       The  320K  version  of  AnalytiCalc differs from the normal 256K
  4363.  version in two ways:  it is not overlaid,  and  it  supports  logical
  4364.  names.  
  4365.  
  4366.       The  256K  version  uses  overlays from disk to save memory, and
  4367.  consequently a spreadsheet that uses many special functions that  are
  4368.  in  different overlays (e.g., large amounts of matrix math plus large
  4369.  amounts of date conversions) will be slowed.  The 320K version is non
  4370.  overlain  and  there  is no penalty for any function mix.  (Actually,
  4371.  some initialization code is in overlays, but this  is  executed  once
  4372.  and then never again, so it exacts no speed penalty.) 
  4373.  
  4374.       The  320K  version also has a symbol table and allows you to de-
  4375.  fine symbolic names of up to 16 characters length, containing letters
  4376.  or numbers, and use them inside equations.  
  4377.  
  4378.       To define a symbolic name, use the command 
  4379.  
  4380.  TE {SYMBOLICNAME=Vn 
  4381.  
  4382.  where Vn is a cell name (like A5, R17, AB122, or the like), and "SYM-
  4383.  BOLICNAME" is the name you wish to define.  The  name  is  now  asso-
  4384.  ciated with the CONTENTS OF the cell named (as Vn).  When you use the
  4385.  construct {SYMBOLICNAME in an equation, the contents of the cell  as-
  4386.  sociated  with  that  name replace the name prior to evaluation.  Any
  4387.  contents may be used, though the total resulting string must not grow
  4388.  to  over  109 characters.  Recursive substitutions are permitted to a
  4389.  depth of 20, so name definitions may use other name definitions.  
  4390.  
  4391.       To remove a name definition, use the command 
  4392.  
  4393.  TE {SYMBOLICNAME=0 
  4394.  
  4395.  You  should  remove definitions explicitly since they are not automa-
  4396.  tically removed by adding new definitions.  
  4397.  
  4398.       Up  to 301 names may be defined in the sheet.  Note that scratch
  4399.  cells A0 through approximately BK0 may be used to hold definitions if
  4400.  desired.  
  4401.  
  4402.       To  store  cell  definitions  for later use, the special command
  4403.  must be used as follows to save them:  
  4404.  
  4405.  TE {*= 
  4406.  
  4407.  This  will  cause  AnalytiCalc  to ask for an Output file.  You reply
  4408.  
  4409. AnalytiCalc Reference Manual                                   Page 87
  4410.  
  4411.  
  4412.  
  4413.  with a filename to store (or show) the definitions.  The program will
  4414.  then  dump  all known symbol definitions in the same format needed to
  4415.  do the definitions of the names.  If a disk file is specified, it can
  4416.  be read in via the @file command so the symbols may be redefined to a
  4417.  later AnalytiCalc run.  
  4418.  
  4419.       Storing  definitions  on CON:  can give a quick look at them in-
  4420.  teractively, but usually it is better to print the definitions (which
  4421.  can  be  done by giving LPT1:  (or your printer's real name if that's
  4422.  not it) as the output file name.  
  4423.  
  4424.       This  facility can save considerable formula typing time.  Where
  4425.  you have a very large formula to be duplicated many times, if it  can
  4426.  be  specified  relocatably,  a  reference to a short name (or a cell,
  4427.  since {name and {cell function the same) can save storage  and  allow
  4428.  you to get by with smaller disk work files.  The 256K AnalytiCalc has
  4429.  the {cell logic to do substitutions,  but  the  names  must  be  cell
  4430.  names.  Only the larger one has room for the name dictionary.  
  4431.  EXAMPLE RUN:
  4432.  
  4433.  L D0                    ;  go to phantom cell D0
  4434.  ET SUM[A1:A4]           ;  fill in a macro definition as text
  4435.  TE {SALES=D0            ;  define "sales" as this sum
  4436.  M2                      ;  set automatic motion down
  4437.  L A1                    ;  go to A1 
  4438.  E 2.3                   ;  enter some junk data just to show this
  4439.  E 4.86
  4440.  E 1.2647
  4441.  E 8.3454
  4442.  EV {SALES               ;  Enter sales value as a numeric.
  4443.          ;  the cell will display the sum of A1 thru A4.
  4444.  
  4445.  An example position independent formula might be:  
  4446.  
  4447.  SUM[ P#0#-5:P#0#-1] 
  4448.  
  4449.  which  means  the  sum of the cells from 5 above the current physical
  4450.  cell to 1 above the physical cell.  This form if used in a name  will
  4451.  work wherever it is used, regardless of location.  
  4452.  
  4453. AnalytiCalc Reference Manual                                   Page 88
  4454.  
  4455.  
  4456.  
  4457.                               Appendix D
  4458.                      AnalytiCalc Function Summary
  4459.  
  4460.  
  4461.       The available multiple argument functions are:  
  4462.    SUM[variables]     Sum of all arguments
  4463.    MAX[variables]     Max of arguments
  4464.    MIN[variables]     Min of arguments
  4465.    AVG[variables]     Average of arguments
  4466.    AVE[variables]     Average of arguments excluding zero args
  4467.    STD[variables]     Standard deviation squared
  4468.    AND[variables]     Boolean AND of all variables in list
  4469.    IOR[variables]     Boolean inclusive OR of variables
  4470.    NOT[variable]      Boolean complement of variable
  4471.    XOR[v1,v2]         Boolean exclusive OR of v1,v2
  4472.    EQV[V1,V2]         Boolean "equivalence" of V1,V2
  4473.                       (complement of exclusive OR, true if
  4474.                       bits have the SAME value)
  4475.    CNT[variables]     Number of nonzero variables in list
  4476.    MOD[V1,V2]         Returns V1 modulo V2 (i.e., remainder
  4477.                       of V1/V2 division.)
  4478.    SGN[v1]            Returns 1.0 times sign of V1
  4479.    LKP[var,variables] Lookup variable in "variables" range
  4480.                       greater or equal to var, return its
  4481.                       index (starting with 0) into variables
  4482.                       range.
  4483.    LKN[var,variables] Lookup variable in "variables" range
  4484.                       less than or equal to var, return its
  4485.                       index (starting with 0) into variables
  4486.                       range.
  4487.    LKE[var,variables] Lookup variable in "variables" range
  4488.                       strictly equal to var, return its index
  4489.                       (starting with 0) into range. Note all
  4490.                       LKP, LKN, LKE return the last variable
  4491.                       index if no satisfactory value found.
  4492.    NPV[disc,vars]     Net Present Value of vars (equal time
  4493.                       interval numbers), at discount rate
  4494.                       disc where disc is a fraction
  4495.                       (e.g., .12 for 12%)
  4496.    IRR[PV,FV,returns] Internal Rate of Return. Will compute
  4497.                       internal rate of return on up to 20
  4498.                       periods, returning rate per period.
  4499.                       The returns are expected to be at
  4500.                       equal time intervals. PV and FV are
  4501.                       initial and final values of investment
  4502.                       and the result is computed via Newton
  4503.                       approximation.
  4504.     PMT[princ,inter,nper] Payment (mortgage payment per period)
  4505.                       function. Will compute payment per period
  4506.                       for principal amount "princ" with interest
  4507.  
  4508. AnalytiCalc Reference Manual                                   Page 89
  4509.  
  4510.  
  4511.  
  4512.                       per period as "inter" and number of periods
  4513.                       as "nper". All arguments must be cells.
  4514.                       The formula is the standard ordinary annuity
  4515.                       formula. Interest rate must be a fraction so
  4516.                       that 14% would be 0.14, for example.
  4517.     PVL[payment,inter,nper] Present Value formula. Computes present
  4518.                       value of an annuity given "payment", the payment
  4519.                       per period, interest rate per period (as a
  4520.                       fraction, so 12% is 0.12) in "inter", and
  4521.                       number of periods as "nper". All arguments
  4522.                       must be in cells.
  4523.     RND[DUM]          Generates a random number between 0. and
  4524.                       1.0. An argument is needed but it is
  4525.                       NOT touched by this function.
  4526.  .INDEX Random numbers
  4527.  .Index RND function
  4528.  
  4529.     IF [V1.rel.V2] statement | else-statement
  4530.      Compares two variables and executes either "statement" (if the
  4531.       relation is true) or "else-statement" (if the relation is
  4532.       false).
  4533.      Valid relations (in the place of the .rel. above) are:
  4534.        .EQ.    Equal
  4535.        .NE.    Not Equal
  4536.        .GT.    Greater than (V1 greater than V2)
  4537.        .LT.    Less than (V1 less than V2)
  4538.        .GE.    Greater than or Equal to (V1 >= V2)
  4539.        .LE.    Less than or Equal to (V1 =< V2)
  4540.  
  4541.  
  4542.       The following special constructs in a formula act as functions: 
  4543.           _@V1,V2  Means  get  the  values stored in V1 and V2 and use
  4544.                them as column and row locations pointing at some  cell
  4545.                in  the  sheet.  Replace the construct with the name of
  4546.                that cell.  
  4547.           _#V1  Means take the real number in cell V1 and unpack it as
  4548.                if it had been a packed value from  a  formula  with  8
  4549.                characters packed;  then convert it back into ASCII and
  4550.                place in the formula in place of this construct.   This
  4551.                construct  is  intended  to  be  used with the *U STRVL
  4552.                function to allow retrieval and edit of formulas.   The
  4553.                *U XQTCM  function  permits  use  of  the  EDit command
  4554.                within a cell for string manipulation.  
  4555.  
  4556.       The following single argument functions are available:  
  4557.  
  4558.   FUNCT NAME   ARG TYPE    FUNCT VALUE   DESCRIPTION
  4559.   -------------------------------------------------------
  4560.   ABS          REAL        REAL         absolute value
  4561.   DABS         REAL        REAL         absolute value
  4562.  
  4563. AnalytiCalc Reference Manual                                   Page 90
  4564.  
  4565.  
  4566.  
  4567.   IABS         INTEGER     INTEGER      absolute value
  4568.   IFIX         REAL        INTEGER      REAL to INT conv.
  4569.   AINT         REAL        REAL         REAL truncation
  4570.   INT          REAL        INTEGER      REAL to INT conv.
  4571.   IDINT        REAL        INTEGER      REAL to INT conv.
  4572.   EXP          REAL        REAL         e**X
  4573.   DEXP         REAL        REAL         e**X
  4574.   ALOG         REAL        REAL         natural logarithm
  4575.   DLOG         REAL        REAL         natural logarithm
  4576.   ALOG10       REAL        REAL         logarithm base 10
  4577.   DLOG10       REAL        REAL         logarithm base 10
  4578.   SQRT         REAL        REAL         square root
  4579.   DSQRT        REAL        REAL         square root
  4580.   SIN          REAL        REAL         trigonometric sine
  4581.   DSIN         REAL        REAL         trigonometric sine
  4582.   COS          REAL        REAL         trig. cosine
  4583.   DCOS         REAL        REAL         trig. cosine
  4584.   TANH         REAL        REAL         hyperbolic tangent
  4585.   DTANH        REAL        REAL         hyperbolic tangent
  4586.   ATAN         REAL        REAL         arc tangent
  4587.   DATAN        REAL        REAL         arc tangent
  4588.  
  4589.  
  4590.       The following "equation commands" also act as functions with the
  4591.  effects described:  
  4592.   *@filename      Where  filename  is  the name of a file of CALC com-
  4593.                mands.  CALC reads the file and executes the commands. 
  4594.   *ASCII     Declares a list of variables to be of type ASCII.  
  4595.   *C     COMMENT line.  
  4596.   *N     NOVIEW.  
  4597.   *V     VIEW.  Controls printing options in K mode 
  4598.   *R     READ.  Allows a single line to be read from the terminal.  
  4599.   *REAL     declares specified variables to be REAL*8.  
  4600.   *DECIMAL     Declares specified variables to be REAL*8.  
  4601.   *S     STOP.  Same as *E.  Goes back to spreadsheet.  
  4602.   *E     EXIT.  Gets out of K mode, back to spreadsheet mode.  
  4603.   *Z     ZERO.  Zeroes all accumulators.  
  4604.   *G        *G  V1,V2  (where V1 and V2 are cell or accumulator names)
  4605.                will evaluate V1 and V2 as the column and row  numbers,
  4606.                on  the  physical  sheet, of the desired cell.  The ad-
  4607.                dressed cell's value  is  retrieved  and  used  as  the
  4608.                resulting number.  
  4609.   *W        Takes  the  value at the current cell and writes it out to
  4610.                the formula as a numeric  (floating)  value.   The  *WF
  4611.                command  stores the cell similarly, but uses the format
  4612.                of the current cell instead of the D32.25  format  used
  4613.                for *W.  
  4614.   *P        The  *P  command  resets  the current cell coordinate from
  4615.                within a cell (until the next cell is evaluated  only).
  4616.                It has several forms:  
  4617.  
  4618. AnalytiCalc Reference Manual                                   Page 91
  4619.  
  4620.  
  4621.  
  4622.              *P - By itself, *P causes Calc to prompt for the new phy-
  4623.                sical column and row number.  
  4624.              *P V1 - This moves the current location to the named cell
  4625.                where V1 is the cell name (e.g.  A5, H2) 
  4626.              *P@  V1,V2  -  This uses V1 and V2 (cell names) as column
  4627.                and row numbers and changes the current  physical  cell
  4628.                position  to  that  defined by the contents of cells V1
  4629.                and V2.  This gives complete addressing  of  the  sheet
  4630.                from within any cell.  
  4631.   *F         *F Label - If the value in % is positive and nonzero this
  4632.                command rewinds the input file for  the  AnalytiCalc  @
  4633.                command  and seeks a line beginning with the characters
  4634.                *CLabel (where "label" is what you  put  after  the  *F
  4635.                command).  
  4636.   *J         *J  Label  -  This  command behaves as the *F command but
  4637.                operates on the file used by the Calc *@ command rather
  4638.                than the AnalytiCalc one.  
  4639.   *QF 
  4640.   *QW         The  *QF  (Float)  or  *QW  (write) commands are used to
  4641.                examine sequential files  created  outside  AnalytiCalc
  4642.                and return values or formulas.  Their syntax is 
  4643.            *QF filename ?key1?  ?key2?  <lm> 
  4644.         or *QW filename ?key1?  ?key2?  <lm> 
  4645.                where ?key2?  is optional 
  4646.                l  and  m are delimiter characters for start and end of
  4647.                the parts of the selected records to extract  (defaults
  4648.                to  first part of the record) filename is just the file
  4649.                specifier in the host OS.  The *QF command gets a  part
  4650.                of  a record containing the keys specified and turns it
  4651.                into a number ("floats" it).  The  *QW  command  Writes
  4652.                that  part  of  the  record  to a formula.  The special
  4653.                characters  in  the  <lm>  part  of  the  command   are
  4654.                delimiters of the area to be picked out.  Variant forms
  4655.                allow such choosing to be by column number  instead  of
  4656.                key character if needed.  
  4657.  
  4658.   *U YRMOD VY,VM,VD 
  4659.  
  4660.                returns  the  Julian date (in %) computed from the Year
  4661.                (in VY), the month (in VM) and the day (in  VD),  where
  4662.                VY,  VM,  and  VD  are  sheet  cells.  These may be the
  4663.                result of date arithmetic.  
  4664.  
  4665.   *U JDATE Var 
  4666.  
  4667.                assumes  the  formula in cell Var (any spreadsheet cell
  4668.                name) contains a date string in  the  format  YY/MM/DD.
  4669.                It reads this formula and converts the date to a Julian
  4670.                date, returning it in the % accumulator.  
  4671.  
  4672.  
  4673. AnalytiCalc Reference Manual                                   Page 92
  4674.  
  4675.  
  4676.  
  4677.   *U JTOCH Jul,Var 
  4678.  
  4679.                assumes  that  variable Jul (any spreadsheet cell) con-
  4680.                tains a Julian date and changes it into an ASCII string
  4681.                in the cell whose name is in the Var position here.  
  4682.  
  4683.   *U DATE VY,VM,VD,Var 
  4684.  
  4685.                uses  VY,  VM,  and VD as year, month and day, and com-
  4686.                putes a Julian date from them.   It  then  composes  an
  4687.                ASCII  string of form YY/MM/DD for that date and stores
  4688.                in the formula for Var.  
  4689.  
  4690.   *U WKDYS D1,D2 
  4691.  
  4692.                computes the number of workdays between Julian dates D1
  4693.                and D2 just as taking  the  difference  of  two  Julian
  4694.                dates gives differences between calendar dates in days. 
  4695.  
  4696.   *U WKDIN D1,N1 
  4697.  
  4698.                returns  a  Julian  date that is N1 work days after the
  4699.                date in D1.  
  4700.  
  4701.   *U IDATE() 
  4702.  
  4703.                returns the current date as a Julian day.  
  4704.  
  4705.   *U MTXEQ(AA:AA,XX:XX,BB:BB) 
  4706.  
  4707.                solves  equation  AX=B  where A, X, and B are matrices,
  4708.                and where the notation AA:AA means  two  cells  at  the
  4709.                upper  left  and  lower  right  edges of matrix A (e.g.
  4710.                B2:C3 for the 2 X 2 matrix so defined), and  the  XX:XX
  4711.                and  BB:BB  notation means the same for the X and B ma-
  4712.                trices.  
  4713.  
  4714.   *U MOVEV mtxa,mtxb 
  4715.  
  4716.                moves values from mtxa to mtxb (useful prior to calling
  4717.                MTXEQ).  
  4718.  
  4719.   *U MDET mtx 
  4720.  
  4721.                This  function  computes and returns the determinant of
  4722.                matrix mtx.  
  4723.  
  4724.   *U MPROD A,B,C 
  4725.  
  4726.                This function will multiply matrix A by matrix B giving
  4727.  
  4728. AnalytiCalc Reference Manual                                   Page 93
  4729.  
  4730.  
  4731.  
  4732.                matrix C, provided that their dimensions  are  compati-
  4733.                ble.  
  4734.  
  4735.   *U MADDV A,B,C 
  4736.  
  4737.                This  function  adds matrix A to matrix B and stores in
  4738.                matrix C.  All matrices must have the same dimensions. 
  4739.  
  4740.   *U MSUBV A,B,C 
  4741.  
  4742.                This  function subtracts matrix B from matrix A leaving
  4743.                the result in matrix C.  
  4744.  
  4745.   *U MMPYT A,B,C 
  4746.  
  4747.                This function multiplies matrix A-transpose by matrix B
  4748.                and stores the result in matrix C;  dimensions must  be
  4749.                compatible.  
  4750.  
  4751.   *U MMPYC A,B,K 
  4752.  
  4753.                This  function  multiplies every element of matrix A by
  4754.                constant K.  
  4755.  
  4756.  
  4757.   *U VARY X,A,W,I,P;Q;R;S;T;U;V;W 
  4758.  
  4759.                (Equation Solving by Iterative Search) 
  4760.  
  4761.                This   function  allows  AnalytiCalc  to  automatically
  4762.                search for solutions to equations over up to  8  dimen-
  4763.                sions.  The operation is that the accumulators named in
  4764.                the fields shown as P;Q;R;S;T;U;V;W (one to  8  may  be
  4765.                specified,  only one is required) are varied by a frac-
  4766.                tion W about their initial values (later scaled down by
  4767.                the  gradient of the change in X) to attempt to get ac-
  4768.                cumulator or cell X to equal  accumulator  or  cell  A.
  4769.                This  is  done for I iterations, where I is another ac-
  4770.                cumulator.  
  4771.  
  4772.   *U XQTCM command   will  execute  the  command  (terminated  by  the
  4773.                end-of-line), with any command except X or K permitted,
  4774.                from  inside  a cell.  This allows command files driven
  4775.                from cells to control moving data, etc.  
  4776.  
  4777.   *U STRVL V1,start;len 
  4778.  
  4779.                will  return  a  value  that  is  made  from  up  to  8
  4780.                characters in the FORMULA of cell V1 (where V1  is  any
  4781.                cell name), starting at character "start" and for "len"
  4782.  
  4783. AnalytiCalc Reference Manual                                   Page 94
  4784.  
  4785.  
  4786.  
  4787.                characters.  
  4788.  
  4789.   *U HERE 
  4790.  
  4791.                will  return the current location on the matrix and the
  4792.                current maximum row and column used.  
  4793.  
  4794.   *U FFTFW and *U FFTRV perform Fast Fourier Transforms in the forward
  4795.                and reverse (inverse) directions on the given range  of
  4796.                data.  
  4797.  
  4798.   *U LINEF Vy:Vy,Vx:Vx (with the Vx range optional) fits a line to the
  4799.                input range.  y=Ux+T, err in %, corr coef. in W.
  4800.   *XV filename V1 
  4801.   *XF filename V1        The *X class commands are for sheet linkages. 
  4802.                *XF  loads  a  Formula  from another saved spreadsheet,
  4803.                while *XV loads a Value.  
  4804.  
  4805.  
  4806.  
  4807.       The  following  *U  DBxxxxxx functions also exist as commands of
  4808.  form FILxxxxxx with the same results.  
  4809.  
  4810.  
  4811.  
  4812.   *U  DBOPINS  range  filename  Open  input sequential on filename for
  4813.                cells in range When the input  file  is  open  and  any
  4814.                operation  causes  a read of the cell, the FORMULA will
  4815.                be taken from the file and used.  If the file is opened
  4816.                with  the OPINU option (for Update), then when the FOR-
  4817.                MULA of the cell is written, it will also write to  the
  4818.                file.   The  OPINU option applies only to random access
  4819.                files.  Initially both input and output reads are  dis-
  4820.                abled  (ENAINP and ENAOUT enable them).  When a sequen-
  4821.                tial file (or  device  such  as  a  mailbox,  pipe,  or
  4822.                communications  line) is used for input, it is advanta-
  4823.                geous to read data into  a  range  once,  then  disable
  4824.                input/output  again,  to allow it to be handled between
  4825.                these commands.  The EDTINP  and  FMTOUT  commands  are
  4826.                designed   to   do  this  to  make  it  easier  to  use
  4827.                AnalytiCalc for a filter between sequential files.  
  4828.  
  4829.   *U DBOPINR range filename Open input random on filename for cells in
  4830.                range 
  4831.  
  4832.   *U DBOPINU range filename Open range for update on filename for read
  4833.                and write as random access.  skip 1 
  4834.   *U DBCLSINP Close input 
  4835.  
  4836.   *U DBCLSOUT Close output 
  4837.  
  4838. AnalytiCalc Reference Manual                                   Page 95
  4839.  
  4840.  
  4841.  
  4842.  
  4843.   *U  DBOPOUTS  range filename Open output sequential from range cells
  4844.                to filename 
  4845.  
  4846.   *U DBOPOUTR range filename Open output random from range on filename 
  4847.  
  4848.   *U DBENAINP Enable input file readin (initially disabled) 
  4849.  
  4850.   *U DBENAOUT Enable output write (initially disabled) 
  4851.  
  4852.   *U DBDISINP Disable input area readin 
  4853.  
  4854.   *U DBDISOUT Disable output write 
  4855.  
  4856.   *U DBEDTINP range Enables input and output and, for each cell in the
  4857.                given range, reads and writes the  cell,  allowing  the
  4858.                file  read/writes to take effect.  Each cell is flagged
  4859.                as valid but of text type;  the DF command must be used
  4860.                to  reset  any  that  should  be treated as computable.
  4861.                Input and output are disabled on completion of the com-
  4862.                mand.  
  4863.  
  4864.   *U DBFMTOUT range 
  4865.   *U  DBVALOUT range Enables input and output and for each cell of the
  4866.                range takes the VALUE of the cell, reads the cell, sets
  4867.                it  of text type, and writes the text equivalent of its
  4868.                value to the cell.  In the FMTOUT  command  the  cell's
  4869.                display  format  is  used  for  the conversion.  In the
  4870.                VALOUT command a large builtin format is used  to  pre-
  4871.                serve  all  significant  digits.   Spaces are discarded
  4872.                prior to output.  Cells  are  left  containing  textual
  4873.                data  corresponding  to their numeric values, stored in
  4874.                the formulae.  The DF command  may  be  used  to  reset
  4875.                these  cells  to  numeric types if desired.  Conversion
  4876.                errors are ignored.  Input and output are  disabled  on
  4877.                completion of the command.  
  4878.  
  4879.   *U DBCMPFRM V1:V2[,V3:V4] Compares two formulas.  It returns, in the
  4880.                % accumulator, the index of the formula in cell  V2  in
  4881.                the formula in cell V1.  Lengths used are those of both
  4882.                formulas UNLESS the V3 and V4 cell arguments are  seen.
  4883.                In that case the value of V3 will be used as the length
  4884.                of the formula for V1 and the value of V4 will be  used
  4885.                as  the length of cell V2.  If either value in V3 or V4
  4886.                is outside the range 1 to 109 both values in V3 and  V4
  4887.                will be ignored.  Also on output the W accumulator will
  4888.                be set to -1.  if V1 is lexically earlier than  V2,  0.
  4889.                if  they  are  lexically equal, and +1.  if V1 is lexi-
  4890.                cally later than V2.  
  4891.  
  4892.  
  4893. AnalytiCalc Reference Manual                                   Page 96
  4894.  
  4895.  
  4896.  
  4897.   *U  DBLENFRM  V1:V2 returns the length of the formula for cell V1 in
  4898.                the % accumulator and in cell V2 IF CELL V2  IS  VALID.
  4899.                Otherwise  the  cell specified in V2 is ignored, though
  4900.                it must be present in the command or function.  
  4901.  
  4902.   *U  DBTRMFRM  V1:V2,V3,V4 Reads the formula in V1 and uses V3 and V4
  4903.                as start and end byte numbers within it.  It returns to
  4904.                V2 the formula that is between the start and end bytes,
  4905.                trimming the V1 formula into V2 by chopping out the un-
  4906.                desired  parts.  The find substring function CMPFRM can
  4907.                be used to find delimiter bytes  if  absolute  columnar
  4908.                formatting  is not desired.  As in all these functions,
  4909.                CMPFRM and LENFRM have the forms 
  4910.  
  4911. AnalytiCalc Reference Manual                                   Page 97
  4912.  
  4913.  
  4914.  
  4915.                               Appendix E
  4916.                              NEW FEATURES
  4917.  
  4918.       The  following features were added to AnalytiCalc after the last
  4919.  edit to the manual:  
  4920.  
  4921.       1.  Extended cell addressing.  
  4922.  
  4923.       This  feature  allows  you to treat the spreadsheet as though it
  4924.  contained 18000 rows and 18000 columns.  You can use any  storage  in
  4925.  any  part of this range.  Thus, columns from A through ZPH are legal,
  4926.  and rows from 1 to 18000 are legal.  
  4927.  
  4928.       The actual storage in virtual memory is still treated as a prime
  4929.  area of 60 by 300 cells, but extended areas move down  the  sheet  as
  4930.  you go further to the right of the 60 columns, and right on the sheet
  4931.  as you go further down.  The increments on overflow start at 50  rows
  4932.  and  10  columns, but can be reset by questions in the "modify widths
  4933.  and mapping" section of the S (setup) command.  The  mappings  chosen
  4934.  are saved and restored in PP and GP commands.  
  4935.  
  4936.       This  allows  you  to use the storage as a giant area, though it
  4937.  can run out.  (No possible PCDOS machine could really compute  a  325
  4938.  million cell sheet, if all cells were full, quickly enough to be use-
  4939.  ful.) 
  4940.  
  4941.       Because  it can be confusing to figure out what is going on, the
  4942.  Add (AR and AA) commands that insert or delete whole rows or  columns
  4943.  do  not  work  in extended addresses (i.e., beyond 60 columns and 300
  4944.  rows).  When using extended addressing, and after you have cells  set
  4945.  up  in the extended area, you should NOT alter the mappings via the S
  4946.  command, nor should you use the AA or AR commands.   All  other  com-
  4947.  mands work normally.  
  4948.  
  4949.       2.   A  new  version  of  the  compiler  means  the 80287 is now
  4950.  detected automatically for the IBM AT and  its  lookalikes.   You  no
  4951.  longer  need  to  set  the NO87 parameter if you have an 80286 but no
  4952.  80287.  The 80287 will be detected and used automatically if present.
  4953.  (Note:   if  the 80287 is connected differently from the way it is in
  4954.  an IBM AT, you may need a special version of AnalytiCalc.   Write  to
  4955.  General  Cybernetic Engineering, PO Box 748, Mt.  Holly, NJ 08060 for
  4956.  information.  If you bought an IBM version,  it  can  be  traded  for
  4957.  another PROVIDED you can tell us how the 80287 is set up for you.  We
  4958.  may have to supply a software-math version if this problem is  really
  4959.  difficult.  
  4960.  
  4961.       3.  The sheet save and restore now saves values in a PPX command
  4962.  as well as formulas.  It also saves column widths and the  number  of
  4963.  rows  and  columns being displayed.  If you specify a 4th character M
  4964.  in the command (e.g., PPXM instead of  just  PPX),  AnalytiCalc  will
  4965.  
  4966. AnalytiCalc Reference Manual                                   Page 98
  4967.  
  4968.  
  4969.  
  4970.  save  the  display-to-physical  mapping in its saved sheet as well as
  4971.  the other sheet information.  This  considerably  extends  the  saved
  4972.  size, so it is optional.  Setting up your mapping while journaling is
  4973.  turned on, and then playing back a journal file, will still use  sub-
  4974.  stantially  less  disk  space, though having all the information in a
  4975.  saved sheet makes reload simpler.  
  4976.           The PP commands have now the following effects:  
  4977.           PPN  Save  numerical values (and labels) only.  Formulas are
  4978.                NOT stored;  only numeric values are.  
  4979.           PPX Save both numeric values and formulas.  The output files
  4980.                contain two records per cell used, one  containing  the
  4981.                value and the other containing the formula.  On reload,
  4982.                the value record sets the cell value, and  the  formula
  4983.                record  sets  the formula (which may cause the value to
  4984.                change once a recalculation is done).  The value record
  4985.                is  first  and it's first character is "p" (lower case)
  4986.                while the  formula  record's  first  character  is  "P"
  4987.                (upper  case).  See the BASIC graphics programs for how
  4988.                to read the format, or type a saved sheet  out  to  see
  4989.                how it looks.  Use this form of save for most purposes. 
  4990.           PPF  Saves formulas only, not values (though a single recal-
  4991.                culation generally produces values).  Use this for tem-
  4992.                plates  where  the data values are not meaningful or to
  4993.                save room.  This sort of save cannot  however  be  used
  4994.                for  graphics, and the *XV command will not find useful
  4995.                values everywhere in such a saved sheet.  
  4996.           PDN  Saves  Display sheet numerically only.  Like PPN except
  4997.                that the offsets used are in Display  coordinates,  not
  4998.                relative to the physical sheet.  
  4999.           PDF  Saves  Display  sheet, Formulas only.  No display sheet
  5000.                save of "both"  numbers  and  formulas  is  implemented
  5001.                since  the  display  sheet is smaller than the physical
  5002.                one and two saves can be  easily  done  when  both  are
  5003.                needed.  
  5004.           PxxM Where "xx" can be PN, PF, DN, DF, or PX - Saves Mapping
  5005.                as well as the sheet.  This saves extra  records  (with
  5006.                row  and  column  numbers  offset by 64000 to keep them
  5007.                from confusing graphics programs) that allow Get (GP or
  5008.                GD  or  GPR) commands to set up the display to physical
  5009.                sheet mappings automatically.  Thus, you can  save  all
  5010.                your  windows  and  have  them  back  automatically  on
  5011.                reload.  The mapping is saved from the  current  cursor
  5012.                location down and right only.  
  5013.           The  G  (Get)  class commands are unchanged except that they
  5014.                now reset all the new saved quantities  when  they  are
  5015.                seen.   Old saved sheets receive default values for the
  5016.                column widths, numbers of rows/columns,  mapping,  etc.
  5017.                so their behavior is not altered.  
  5018.  
  5019.  
  5020. AnalytiCalc Reference Manual                                   Page 99
  5021.  
  5022.  
  5023.  
  5024.       V18-04 has the following new features:  
  5025.  
  5026.       1.   If  you have an ACINIT.PRM file, it will be kept open as an
  5027.  initializer file until EOF and may contain any AnalytiCalc  commands.
  5028.  HOWEVER, if you use the file, it MUST contain at least the replies to
  5029.  all questions until you  arrive  at  the  spreadsheet's  "calculation
  5030.  screen".   It  can  be  used to preset cell contents or perform other
  5031.  setups.  Note that the ZA command allows you to reset storage parame-
  5032.  ters  and  the  like, so having them preset by a startup file in this
  5033.  way does not reduce the generality of the program.   It  is  often  a
  5034.  good  policy to do this to get the program started, as the setup com-
  5035.  mand can contain typed strings to initialize ANSI.SYS or  to  set  up
  5036.  internal  function key meanings without having to rely on an operator
  5037.  or   an   external   batch   file   to   do    so.     The    command
  5038.  %escape sequence to type%*%*% will just type the escape sequence;  it
  5039.  may be used in ACINIT.PRM (after the part that answers initial  ques-
  5040.  tions)  to  type any desired escape sequences for setting up ANSI.SYS
  5041.  or whatever if that screen control method is chosen.  
  5042.  
  5043.       2.   If  you  type  a  control-Z  at  some  places (e.g., to the
  5044.  Filename> prompt for the PPX command), the OTS  does  not  close  and
  5045.  re-open the console input file.  This used to cause fatal errors, but
  5046.  now console control is partially maintained.  To enter multistep com-
  5047.  mands  from the console, however, it is necessary to set up to use an
  5048.  auxiliary input dataset.  If you type control-Z  on  input,  you  may
  5049.  need to use the command 
  5050.  
  5051.                                @\DEV\CON 
  5052.  
  5053.  to  set  input  from the console.  Then save your sheet and exit, and
  5054.  rerun the program.  If you type control Z somewhere on input  and  it
  5055.  appears  that  the console is still closed (symptoms are that "secon-
  5056.  dary questions" like the  confirm  reply  on  exit  return  instantly
  5057.  without  giving  you a chance to reply), here's the fix.  Just type a
  5058.  control - Z where at a command prompt.  The program will flash a mes-
  5059.  sage  *eof*  and  try  to get input again.  Generally this clears the
  5060.  console channel and gets it open correctly, overcoming a bug  in  the
  5061.  MS Fortran OTS.  
  5062.  
  5063.       3.   You  now  no longer really need ANSI.SYS!  Input is handled
  5064.  via single character I/O from the console now, and where any extended
  5065.  function  in  the range 59 through 83 is seen, the command is changed
  5066.  for you to _{Ac where c ranges from B (for 59) to Z (for  83).   Thee
  5067.  extended  function 59-68 are F1 through F10.  The up, down, left, and
  5068.  right arrow functions are 72, 80, 75, and 77.  For others see your PC
  5069.  documents (or auxkpd.txt) for equivalents.  
  5070.  
  5071.       By  placing  any desired equivalence command text into cells AB0
  5072.  through AZ0 formulas, you can make any of the relevant function  keys
  5073.  acquire  any desired meaning.  The ACINIT.PRM file can be preset with
  5074.  
  5075. AnalytiCalc Reference Manual                                  Page 100
  5076.  
  5077.  
  5078.  
  5079.  commands to do this automatically.  For example,  the  following  se-
  5080.  quences allow the arrow keys to work at startup:  
  5081.  
  5082.  L AO0
  5083.  ET 1
  5084.  L AW0
  5085.  ET 2
  5086.  L AR0
  5087.  ET 3
  5088.  L AT0
  5089.  ET 4
  5090.  L A1
  5091.  
  5092.  Note  that AB0 corresponds to code 59, and so on.  AO0 corresponds to
  5093.  72, AW0 to 80, AR0 to 75, and AT0 to 77 here.  The  1,2,3,or  4  that
  5094.  are  entered are the cursor move commands in command mode, entered as
  5095.  text so they cause no calculation overhead.  Note that IF YOU HAVE AN
  5096.  ACINIT.PRM, IT will be read, NOT your console, for initial questions.
  5097.  (You can get the initial queries back with the ZA command however.) 
  5098.  
  5099.  
  5100.  
  5101.                         New Features of V18-07B
  5102.  
  5103.       AnalytiCalc  V18-07B  supports  use  for project management.  To
  5104.  make this run efficiently, the selection functions were  modified  to
  5105.  record  which  cell  was selected.  Thus, the MAX, MIN, LKP, LKN, and
  5106.  LKE functions now return the column and  row  (respectively)  of  the
  5107.  cell  they  find  in accumulators P and Q respectively.  The function
  5108.  "*P@ P0,Q0" may be used to directly access this  cell  in  subsequent
  5109.  calculations,  or the P and Q accumulators can be used in other forms
  5110.  of addressing to access the selected cells.  The functions  otherwise
  5111.  behave as they did in earlier releases.  
  5112.  
  5113.       The   project   management  software  (AnalytiProject)  will  be
  5114.  distributed only to registered (i.e., paying) users of AnalytiCalc.  
  5115.                         New Features - V18-07C
  5116.  
  5117.       AnalytiCalc  V18-07C  adds two functions to support computations
  5118.  in "workdays".  
  5119.  
  5120.          *U WKDYS V1,V2 
  5121.  
  5122.  takes  Julian dates in variables V1 and V2 and computes the number of
  5123.  workdays between the two, not counting the initial date if  it  is  a
  5124.  workday (to be similar to differences between Julian dates).  
  5125.  
  5126.          *U WKDIN V1,V2 
  5127.  
  5128.  takes  a Julian date in V1 and a number of days in V2 and returns the
  5129.  
  5130. AnalytiCalc Reference Manual                                  Page 101
  5131.  
  5132.  
  5133.  
  5134.  Julian date that is V2 workdays after the date in V1.  It is  thus  a
  5135.  sort  of  inverse  for  the *U WKDYS function.  The resulting date is
  5136.  guaranteed to be in the Monday to Friday range.  A workday is  Monday
  5137.  to Friday.  The functions know nothing of holidays.  
  5138.  
  5139.       Note  that  these  functions are in a single overlay in BOTH the
  5140.  256K and the 320K version.  This will have little impact on the  320K
  5141.  version however since once the overlay is loaded it will tend to stay
  5142.  unless displaced by the HELP overlay.  
  5143.                         New Features - V18-08A
  5144.  
  5145.       In  V18-08A,  AnalytiCalc can compute line fits and Fast Fourier
  5146.  transforms on data.  
  5147.  
  5148.          *U LINEF Y1:Y2,X1:X2 
  5149.  
  5150.  computes  a line whose equation is Y=mX+B, where m is returned in the
  5151.  U accumulator and B is returned in the T accumulator.  The %  accumu-
  5152.  lator returns the fitting error in Y.  The line is fit over the range
  5153.  Y1:Y2 in Y, with the X coordinates optional and if they are  present,
  5154.  they  must  be in the cells in the X1:X2 range given.  If the X range
  5155.  is omitted, 1.  to the max.  number of points will be used.  
  5156.  
  5157.          *U FFTFW V1:V2 
  5158.  
  5159.  computes the forward (t to freq) Fourier transform of the range and 
  5160.  
  5161.          *U FFTRV V1:V2 
  5162.  
  5163.  computes the reverse (freq.  to t) transform.  The range  must  be  a
  5164.  power  of two long (if less, the largest power of 2 available is used
  5165.  and extra points are ignored).  Data is assumed to be the real  coef-
  5166.  ficients in the first half and the imaginary ones in the second half.
  5167.  FFT data is returned in this layout also.  Thus, the real data (which
  5168.  is  frequently  the part of interest) is returned first.  The reverse
  5169.  FFT of the forward FFT returns the original data.  The FFT is of  in-
  5170.  terest for finding the frequency distribution of partially sinusoidal
  5171.  distributions.  
  5172.  
  5173.                         New Features - V19.01A
  5174.  
  5175.       A  modified command structure is supported now.  If you type the
  5176.  command /;  then the commands to AnalytiCalc are modified as follows: 
  5177.  
  5178.  
  5179.       1.  Any  command  beginning  with  a digit (except single digits
  5180.           standing alone) is treated as an EV followed by the text.  
  5181.  
  5182.       2.  Any  command beginning with / has the / stripped off and the
  5183.           rest is treated as a command.  
  5184.  
  5185. AnalytiCalc Reference Manual                                  Page 102
  5186.  
  5187.  
  5188.  
  5189.       3.  Any  command  beginning  with  " is treated as an E" command
  5190.           (enter text) with the " stripped out.  
  5191.  
  5192.       4.  Anything not starting with a digit, a " character, or a / is
  5193.           treated as an Enter command and is prefixed with "EN  "  and
  5194.           used.  
  5195.  
  5196.  
  5197.       The old (default) command mode is restored with the command "//"
  5198.  so that /;  and // switch between the two.   These  commands  may  be
  5199.  given  in ACINIT.PRM, other command files, or from the console.  They
  5200.  introduce incompatibilities in that in the new version commands  like
  5201.  "DF  range [format]" must be entered as "/DF range [format]" (for ex-
  5202.  ample) to work.  
  5203.  
  5204.       To  facilitate writing command files that work in both modes the
  5205.  command / switches  the  mode  with  a  save  cell.   A  sequence  of
  5206.  commands:  
  5207.  
  5208.   /#             (save current command mode in save cell)
  5209.   //             (enter old command mode)
  5210.  ...
  5211.   (do all of command file)
  5212.  /#              (restore saved user command mode)
  5213.  
  5214.  will  allow  a command file to operate and be written to run predict-
  5215.  ably in either user environment choice.  
  5216.  
  5217.       Please  NOTE  that special characters in the first character are
  5218.  interpreted as commands in /;  mode.  The * character is handled as a
  5219.  comment.   To  enter formulas with functions starting with *, use the
  5220.  COMMAND form, e.g.  /EV *U IDATE.  This always works  and  disambigu-
  5221.  ates syntax.  
  5222.  
  5223.       When the system is in /;  mode, the cell prompt at the 23rd line
  5224.  of the screen ends with :  so that it appears like 
  5225.  
  5226.  AB 21:  
  5227.  
  5228.       When  the system is in // mode (initial default) the prompt ends
  5229.  with the > character so it appears like 
  5230.  
  5231.  AB 21> 
  5232.  
  5233.  This should aid in distinguishing modes during use.  
  5234.                          New Features of V19.2
  5235.  
  5236.       In  V19.2, AnalytiCalc adds the OAD and ORD commands.  These are
  5237.  like the OA and OR commands except they leave the  relative  mappings
  5238.  of  the  screen alone.  Thus, if you already split your screen into 3
  5239.  
  5240. AnalytiCalc Reference Manual                                  Page 103
  5241.  
  5242.  
  5243.  
  5244.  parts and use the command "OAD cell" to reset the mapping, the resul-
  5245.  tant screen still has 3 regions at the same relative positions as be-
  5246.  fore.  If you use the ORD command, then only the part of  the  screen
  5247.  right and down from the cursor is affected, but any screen partition-
  5248.  ing is maintained.  If these commands leave some  areas  pointing  to
  5249.  nonexistent  areas, use a command OR or OA to reset the areas desired
  5250.  to something real again.  V19.2 added the change from > to :  at  the
  5251.  end of the prompt depending on // or /;  modes also.  
  5252.  
  5253.       New Features - V19-03A 
  5254.  
  5255.       The  recalculation  has added 2 new modes in V19-03, Recalculate
  5256.  Incremental (the initial default), and Recalculate Entry.  
  5257.  
  5258.       The R command re-establishes the old default mode which recalcu-
  5259.  lates ALL formulas  on  the  whole  sheet  for  every  entry  of  new
  5260.  material.  
  5261.  
  5262.       The RI command sets Recalc Incremental mode which recomputes all
  5263.  cells on the display screen, but skips non-displayed cells.  
  5264.  
  5265.       The  RE command sets Recalc Entry mode which ONLY recomputes the
  5266.  newly entered formula, leaving the rest alone.  (It  is  reliable  in
  5267.  the  "prime"  region  of  the  sheet but may fail in extended address
  5268.  areas.) 
  5269.  
  5270.       The  RR command is equivalent to RF (Recalculate, FORCE recompu-
  5271.  tation of constants), EXCEPT that it leaves  the  mode  alone  so  if
  5272.  AnalytiCalc is in RI or RE mode, it stays that way.  
  5273.  
  5274.       Note  a  full  recalculation is done after Get commands (loading
  5275.  saved sheets) regardless of mode.  
  5276.  
  5277.       The  command  ..  (two periods at the start of a line) in a com-
  5278.  mand file closes the command file and returns to the  console.   This
  5279.  has  not  previously  been  documented  though  the function has been
  5280.  present for some time.  
  5281.  
  5282.       It  is recommended that RE or RI mode be used instead of RM mode
  5283.  (which completely disables recalculation) during data entry if  other
  5284.  modes  are too slow.  AnalytiCalc may be obtained from General Cyber-
  5285.  netic Engineering, POB 748, Mt.  Holly, NJ 08060 for $49.95 + $5 S/H. 
  5286.  
  5287. AnalytiCalc Reference Manual                                  Page 104
  5288.  
  5289.  
  5290.  
  5291.                                  INDEX
  5292.  
  5293.  
  5294.  *XV Function 
  5295.  
  5296.  320K version . . . . . . . . . . . . . . . . . . . . . . . . . .   86
  5297.  
  5298.  8087 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5299.  
  5300.  AA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5301.  AA Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   12
  5302.  Access to Saved Sheets . . . . . . . . . . . . . . . . . . . . .   73
  5303.  Accumulators . . . . . . . . . . . . . . . . . . . . . . . . . .   31
  5304.  ACINIT.PRM . . . . . . . . . . . . . . . . . . . . . . . .    99, 100
  5305.  ANSI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   99
  5306.  AR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5307.  AR Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   12
  5308.  Arguments  . . . . . . . . . . . . . . . . . . . . . . . . . . .   31
  5309.  Auto Motion 
  5310.  Availability . . . . . . . . . . . . . . . . . . . . . . . . .    103
  5311.  AVE Function . . . . . . . . . . . . . . . . . . . . . . . .   25, 88
  5312.  AVG function . . . . . . . . . . . . . . . . . . . . . .   25, 27, 88
  5313.  
  5314.  Boolean Functions  . . . . . . . . . . . . . . . . . . .   25, 27, 88
  5315.  
  5316.  C Command 
  5317.  Calculation Order  . . . . . . . . . . . . . . . . . . . . . . .   54
  5318.  Case Conversion  . . . . . . . . . . . . . . . . . . . . . . . .   23
  5319.  Cell Addressing  . . . . . . . . . . . . . . . . . . . . . . . .   97
  5320.  Cell Commands  . . . . . . . . . . . . . . . . . . . . . . . . .   32
  5321.  Cell Names . . . . . . . . . . . . . . . . . . . . . . . . .   34, 89
  5322.  Cell Precision . . . . . . . . . . . . . . . . . . . . . . . . .   79
  5323.  Column Width Set . . . . . . . . . . . . . . . . . . . . . . . .   20
  5324.  Command Arguments  . . . . . . . . . . . . . . . . . . . . . . .   21
  5325.  Command File Limitations . . . . . . . . . . . . . . . . . . . .   35
  5326.  Command Files  . . . . . . . . .   32, 33, 34, 35, 50, 53, 63, 89, 91
  5327.  COMMAND MACROS 
  5328.  COMMANDS . . . . . . . . . . . . . . . . . . . . . . . . . . . .    8
  5329.  Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . .   53
  5330.  Conditional Loops 
  5331.  Conditional Motion . . . . . . . . . . . . . . . . . . . . .   63, 91
  5332.  Console Arguments  . . . . . . . . . . . . . . . . . . . . . . .   53
  5333.  Control Z 
  5334.  Copy 
  5335.  CTTY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .    8
  5336.  Current Position . . . . . . . . . . . . . . . . . . . . . . . .    8
  5337.  Cursor Motion 
  5338.  
  5339.  Data Base Access . . . . . . . . . . . . . . . . . . . . . . . .   33
  5340.  DB Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   14
  5341.  
  5342. AnalytiCalc Reference Manual                                  Page 105
  5343.  
  5344.  
  5345.  
  5346.  DF Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   15
  5347.  Display  . . . . . . . . . . . . . . . . . . . . . . . . . . . .    8
  5348.  Display Format . . . . . . . . . . . . . . . . . . . . . . . . .   15
  5349.  Display Type . . . . . . . . . . . . . . . . . . . . . . . . . .   20
  5350.  Displayed Entity . . . . . . . . . . . . . . . . . . . . . . . .   16
  5351.  DL Command 
  5352.  DS Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   19
  5353.  DT Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   20
  5354.  DW Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   20
  5355.  
  5356.  E Command  . . . . . . . . . . . . . . . . . . . . . . . . . . .   22
  5357.  EDIT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   21
  5358.  EDIT, Special Constructs . . . . . . . . . . . . . . . . . . . .   21
  5359.  EMPTY CELLS 
  5360.  ENTER Command  . . . . . . . . . . . . . . . . . . . . . . . . .   22
  5361.  Equation Solving . . . . . . . . . . . . . . . . . . . . . .   69, 93
  5362.  Exit 
  5363.  Extended Area  . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5364.  Extract Saved Value 
  5365.  
  5366.  F Command 
  5367.  FFT 
  5368.  FFTFW function . . . . . . . . . . . . . . . . . . . . . . . .    101
  5369.  FFTRV Function . . . . . . . . . . . . . . . . . . . . . . . .    101
  5370.  File Loading 
  5371.  File Merging 
  5372.  FORMAT . . . . . . . . . . . . . . . . . . . . . . . . . . .    6, 15
  5373.  FORMAT Microtutorial . . . . . . . . . . . . . . . . . . . . . .   17
  5374.  Formula Indirection  . . . . . . . . . . . . . . . . . . . . . .   29
  5375.  Formula Length . . . . . . . . . . . . . . . . . . . . . . . . .   35
  5376.  FORMULA SEARCH . . . . . . . . . . . . . . . . . . . . . . . . .   50
  5377.  Formula to Text  . . . . . . . . . . . . . . . . . . . . . .   15, 23
  5378.  Formula Value Access . . . . . . . . . . . . . . . . . . . .   72, 93
  5379.  Formulas . . . . . . . . . . . . . . . . . . . . . .   23, 34, 35, 89
  5380.  Fourier Transforms 
  5381.  Frame Editing 
  5382.  Freeze . . . . . . . . . . . . . . . . . . . . . . . . . . .   63, 90
  5383.  Function Arguments 
  5384.  Function Summary . . . . . . . . . . . . . . . . . . . . . . . .   88
  5385.  Functions  . . . . . . . . . . . . . . . . . . .   25, 31, 57, 62, 89
  5386.  FVL (Future Value) function  . . . . . . . . . . . . . . . . . .   88
  5387.  FVL Function . . . . . . . . . . . . . . . . . . . . . . . . . .   25
  5388.  
  5389.  G Command  . . . . . . . . . . . . . . . . . . . . . . . . . . .   37
  5390.  Goal Seeking . . . . . . . . . . . . . . . . . . . . . . . .   69, 93
  5391.  GOTO (Locate) Command  . . . . . . . . . . . . . . . . . . . . .   39
  5392.  Graphics . . . . . . . . . . . . . . . . . . . . . . . . . . . .   44
  5393.  
  5394.  Help . . . . . . . . . . . . . . . . . . . . . . . . . . . .   23, 39
  5395.  Hexadecimal  . . . . . . . . . . . . . . . . . . . . . . . . . .   59
  5396.  
  5397. AnalytiCalc Reference Manual                                  Page 106
  5398.  
  5399.  
  5400.  
  5401.  Histograms 
  5402.  
  5403.  IF conditional . . . . . . . . . . . . . . . . . . . . .   25, 27, 88
  5404.  IF statement . . . . . . . . . . . . . . . . . . . . . . . . . .   30
  5405.  Indirect Addressing 
  5406.  Indirect Cell References . . . . . . . . . . . . . . . . . . . .   32
  5407.  Indirect Command Execution . . . . . . . . . . . . . . . . . . .   71
  5408.  Initialization . . . . . . . . . . . . . . . . . . . . . . . . .   99
  5409.  Input Region . . . . . . . . . . . . . . . . . . . . . . . .   74, 75
  5410.  Insert or Delete Rows or Columns . . . . . . . . . . . . . . . .   12
  5411.  Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . .   20
  5412.  Interactive Calculator . . . . . . . . . . . . . . . . . . . . .   51
  5413.  Internal Loops . . . . . . . . . . . . . . . . . . . . . . . . .   52
  5414.  IRR function (Internal Rate of Return) . . . . . . . . .   25, 27, 88
  5415.  
  5416.  Journaling . . . . . . . . . . . . . . . . . . . . . . . . . . .   50
  5417.  
  5418.  Key Redefinitions  . . . . . . . . . . . . . . . . . . . . . . .   99
  5419.  Keypad Command Files . . . . . . . . . . . . . . . . . . . . . .   24
  5420.  Keypad Commands  . . . . . . . . . . . . . . . . . . . . . .   23, 24
  5421.  Keystroke Capture  . . . . . . . . . . . . . . . . . . . . . . .   50
  5422.  
  5423.  L Command  . . . . . . . . . . . . . . . . . . . . . . . . . . .   39
  5424.  Line Fits  . . . . . . . . . . . . . . . . . . . . . . . . . .    101
  5425.  LINEF function . . . . . . . . . . . . . . . . . . . . . . . .    101
  5426.  Linking Sheets . . . . . . . . . . . . . . . . . . . . . . . . .   36
  5427.  LKP, LKN, LKE Lookup Functions . . . . . . . . . . . . .   25, 27, 88
  5428.  Loading Saved Sheet  . . . . . . . . . . . . . . . . . . . . . .   37
  5429.  Locate current . . . . . . . . . . . . . . . . . . . . . . . . .   39
  5430.  Lookups 
  5431.  Looping  . . . . . . . . . . . . . . . . . . . . . . . .   52, 63, 91
  5432.  
  5433.  M Command 
  5434.  Matrix Algebra . . . . . . . . . . . . . . . . . . . . . . . . .   68
  5435.  Matrix restrictions  . . . . . . . . . . . . . . . . . . . . . .   65
  5436.  MAX function . . . . . . . . . . . . . . . . . . . . . .   25, 27, 88
  5437.  MEMORY USE . . . . . . . . . . . . . . . . . . . . . . . . . . .    7
  5438.  MH Command . . . . . . . . . . . . . . . . . . . . . . . . . . .   40
  5439.  MIN function . . . . . . . . . . . . . . . . . . . . . .   25, 27, 88
  5440.  Mixed Relocatable Names 
  5441.  Mixed Relocation Override  . . . . . . . . . . . . . . . . . . .   30
  5442.  MOD Modulo function  . . . . . . . . . . . . . . . . . .   25, 27, 88
  5443.  Moving . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   39
  5444.  MS command . . . . . . . . . . . . . . . . . . . . . . . . . . .   40
  5445.  Multiple Equations . . . . . . . . . . . . . . . . . . . . .   25, 31
  5446.  
  5447.  New Features . . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5448.  Notes  . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   53
  5449.  NPV (Net Present Value) Function . . . . . . . . . . . .   25, 27, 88
  5450.  NS No Scroll (Scroll Disable)  . . . . . . . . . . . . . . . . .   11
  5451.  
  5452. AnalytiCalc Reference Manual                                  Page 107
  5453.  
  5454.  
  5455.  
  5456.  Number Format  . . . . . . . . . . . . . . . . . . . . . . .   53, 54
  5457.  
  5458.  OA command . . . . . . . . . . . . . . . . . . . . . . . . . . .   41
  5459.  OAD command  . . . . . . . . . . . . . . . . . . . . . . . . . .   41
  5460.  Octal  . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   59
  5461.  OR command . . . . . . . . . . . . . . . . . . . . . . . . . . .   41
  5462.  ORD command  . . . . . . . . . . . . . . . . . . . . . . . . . .   41
  5463.  Origin Control Commands  . . . . . . . . . . . . . . . . . . . .   41
  5464.  Other Features . . . . . . . . . . . . . . . . . . . . . . . . .   77
  5465.  Other Functions  . . . . . . . . . . . . . . . . . . . .   32, 60, 62
  5466.  Output Region  . . . . . . . . . . . . . . . . . . . . . . .   74, 75
  5467.  Overlays . . . . . . . . . . . . . . . . . . . . . . . . . . . .   86
  5468.  
  5469.  P Command  . . . . . . . . . . . . . . . . . . . . . . . . . . .   44
  5470.  PARAMETER SUBSTITUTION 
  5471.  PMT Function . . . . . . . . . . . . . . . . . . . . . . . .   25, 88
  5472.  Position Independent Cell Names  . . . . . . . . . . . . . . . .   35
  5473.  Position Independent Names . . . . . . . . . . . . . . . . . . .   28
  5474.  PPF command 
  5475.  PPX Command  . . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5476.  Prime Area . . . . . . . . . . . . . . . . . . . . . . . . . . .   97
  5477.  Printing Large Reports . . . . . . . . . . . . . . . . . . . . .   19
  5478.  Project Management 
  5479.  
  5480.  Random Numbers 
  5481.  Ranges . . . . . . . . . . . . . . . . . . . . . . . . . . . . .   30
  5482.  RB COMMAND . . . . . . . . . . . . . . . . . . . . . . . . . . .   46
  5483.  RECALCULATE  . . . . . . . . . . . . . . . . . . . . . . . . . .    5
  5484.  Recalculation  . . . . . . . . . . . . . . . . . . . . . . . . .   54
  5485.  Redraw Command . . . . . . . . . . . . . . . . . . . . . . . . .   48
  5486.  Relations  . . . . . . . . . . . . . . . . . . . . . . . . . . .   30
  5487.  RELOCATE BOUNDARY  . . . . . . . . . . . . . . . . . . . . . . .   46
  5488.  Relocation . . . . . . . . . . . . . . . . . . . . . . . . .   12, 35
  5489.  Replicating 
  5490.  RND Function 
  5491.  
  5492.  S Command  . . . . . . . . . . . . . . . . . . . . . . .    7, 44, 97
  5493.  SAVE . . . . . . . . . . . . . . . . . . . . . . . . . . . .    7, 44
  5494.  SC Scroll enable . . . . . . . . . . . . . . . . . . . . . . . .   11
  5495.  Scatter Plots 
  5496.  SCRATCH FILES  . . . . . . . . . . . . . . . . . . . . . . . . .    7
  5497.  Scrolling control  . . . . . . . . . . . . . . . . . . . . . . .   11
  5498.  Self Location  . . . . . . . . . . . . . . . . . . . . . . . . .   72
  5499.  Set Title  . . . . . . . . . . . . . . . . . . . . . . . . . . .    7
  5500.  Setting Number of Cols . . . . . . . . . . . . . . . . . . . . .   14
  5501.  Setting Number of Rows . . . . . . . . . . . . . . . . . . . . .   14
  5502.  Solving For Variables  . . . . . . . . . . . . . . . . . . .   69, 93
  5503.  Sorting  . . . . . . . . . . . . . . . . . . . . . . . .   19, 72, 93
  5504.  Sorting, by ASCII  . . . . . . . . . . . . . . . . . . . . .   72, 93
  5505.  Special Accumulators . . . . . . . . . . . . . . . . . . . . . .   56
  5506.  
  5507. AnalytiCalc Reference Manual                                  Page 108
  5508.  
  5509.  
  5510.  
  5511.  Special Cell Addressing  . . . . . . . . . . . . . . . . . . . .   29
  5512.  Startup control  . . . . . . . . . . . . . . . . . . . . . . .    100
  5513.  STD (Std Deviation) function . . . . . . . . . . . . . .   25, 27, 88
  5514.  Storage Allocation . . . . . . . . . . . . . . . . . . . . . . .   84
  5515.  String Functions . . . . . . . . . . . . . . . . . . . . . .   74, 75
  5516.  Subprocess Execution . . . . . . . . . . . . . . . . . . . . . .   51
  5517.  SUM function . . . . . . . . . . . . . . . . . . . . . .   25, 27, 88
  5518.  Symbolic Names . . . . . . . . . . . . . . . . . . . . . . .   86, 87
  5519.  Symbols  . . . . . . . . . . . . . . . . . . . . . . . . . . . .   86
  5520.  
  5521.  TE Command 
  5522.  Temp.  Escape to Monitor . . . . . . . . . . . . . . . . . . . .   51
  5523.  Temporary Motion 
  5524.  Temporary Move . . . . . . . . . . . . . . . . . . . . . . .   63, 90
  5525.  TEst Compute 
  5526.  Text Entry . . . . . . . . . . . . . . . . . . . . . . . . . . .   23
  5527.  Text to Formula  . . . . . . . . . . . . . . . . . . . . . .   15, 23
  5528.  TITLE  . . . . . . . . . . . . . . . . . . . . . . . . . . . . .    7
  5529.  
  5530.  Value Freeze 
  5531.  Variable Names . . . . . . . . . . . . . . . . . . . . . . . . .   28
  5532.  VARY . . . . . . . . . . . . . . . . . . . . . . . . . . . .   69, 93
  5533.  VIEW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .    5
  5534.  View Command . . . . . . . . . . . . . . . . . . . . . . . . . .   48
  5535.  View Control . . . . . . . . . . . . . . . . . . . . . . . . . .   62
  5536.  
  5537.  W Command  . . . . . . . . . . . . . . . . . . . . . . . . . . .   48
  5538.  Weekdays Functions . . . . . . . . . . . . . . . . . . . . . .    101
  5539.  Where Matrices Can Be  . . . . . . . . . . . . . . . . . . . . .   65
  5540.  Windows  . . . . . . . . . . . . . . . . . . . . . . . . . . . .   41
  5541.  Word Processing  . . . . . . . . . . . . . . . . . . . . . . . .   37
  5542.  Workfiles  . . . . . . . . . . . . . . . . . . . . . . . . . . .   84
  5543.  Writing Screen to File or Print  . . . . . . . . . . . . . . . .   48
  5544.  
  5545.  X Command 
  5546.  
  5547.  ZAP Sheet Command  . . . . . . . . . . . . . . . . . . . . . . .   49
  5548.  ZEro Command . . . . . . . . . . . . . . . . . . . . . . . . . .   49
  5549.  
  5550.  
  5551.